i just created a webservice with visual studio 2010 and .net 4, and published it to my website subdomain. [subdomain has virtual directory and i have set the rules].
when i try to add my webservice to other c# project from "add service refference" => "advanced" => "add web refference" it just show me this error in "webservice found section"
The document at the url http://service.proapp.ir/sedardIP.asmx was not recognized as a known document type.
The error message from each known type may help you fix the problem:
- Report from 'XML Schema' is 'The document format is not recognized (the content type is 'text/html; charset=utf-8').'.
i added .svc application/octet to mime but nothing has changed i added
<webServices>
<protocols>
<add name="HttpSoap"/>
<add name="HttpPost"/>
<add name="HttpGet"/>
<add name="Documentation"/>
</protocols>
</webServices>
too but nothing has changed , can u plz help me?????????????
tried adding refference without advanced throwing this error :
The document at the url service.proapp.ir/sedardIP.asmx was not recognized as a known document type.
The error message from each known type may help you fix the problem:
- Report from 'XML Schema' is 'The document format is not recognized (the content type is 'text/html; charset=utf-8').'.
- Report from 'DISCO Document' is 'There was an error downloading 'service.proapp.ir/service/sedardIP.asmx?disco'.'.
- The request failed with HTTP status 404: Not Found.
- Report from 'http://service.proapp.ir/sedardIP.asmx' is 'The document format is not recognized (the content type is 'text/html; charset=utf-8').'.
- Report from 'WSDL Document' is 'The document format is not recognized (the content type is 'text/html; charset=utf-8').'.
Metadata contains a reference that cannot be resolved: 'service.proapp.ir/sedardIP.asmx'.
Metadata contains a reference that cannot be resolved: 'service.proapp.ir/sedardIP.asmx'.
If the service is defined in the current solution, try building the solution and adding the service reference again.
In my experience, adding your web service reference straight - instead of going in the advanced section - from the service reference panel has never caused me any problem.
Perhaps try that.
Failing that, this will work:
try the same process service reference > add service reference with the following url
http://service.proapp.ir/sedardIP.asmx?WSDL
Related
I keep getting the following parse error:
Server Error in '/' Application.
Parser Error
Description: An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately.
Parser Error Message: Only Content controls are allowed directly in a content page that contains Content controls.
Source Error:
Line 1: ate
Source File: /admin/JobCategories.aspx Line: 1
Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.34248
Problem is, the file in question doesn't have that string ("ate") anywhere in it. I did a search in visual studio for it, and found one file containing it.
Strangely enough, the file was shown as JobCategories(1).aspx. I opened it, and tru enough the string was appended to the start of the file. I deleted it, but the error persists, and now when I search for the string in VS I find no results. Tried restarting IIS, rebuilding the website in VS, and restoring an older version of the file from backup that used to work, but I still get the same error.
Only thing done on the file since the last backup was updating a string in the HTML, nothing to do with the code, and nothing near the beginning of the file.
Any ideas? Thanks.
I have never dealt with ASP.net and I received a folder from a classmate that I need to open up to see the content of the web application. I have tried everything but can't seem to get this application to load properly. I have asked an instructor at my school for assistance and he told me to make sure the instance is correct for SQL server on my computer and for the database to be loaded.
I have found the instance name for SQL server and have placed it in the location where it was originally my classmates instance under add name = "ConnectionString"connectionString="Data Source=(Minh-PC). As for the database I have loaded it up in SQL server under that instance. Am I doing this correctly?
Error messages in Microsoft Visual Studio.
**Warning 1 The 'targetFramework' attribute is not allowed. C:\Users\Minh\Desktop\PanderamaGaming (3)\PanderamaGaming\Web.config 40 20 C:...\PanderamaGaming (3)**
Error 2 It is an error to use a section registered as allowDefinition='MachineToApplication' beyond application level. This error can be caused by a virtual directory not being configured as an application in IIS. C:\Users\Minh\Desktop\PanderamaGaming (3)\PanderamaGaming\Web.config 17
Whenever I load it up it's going straight to a directory and I have an error whenever i try to load the pages.
Error when I try to load the website:
Server Error in '/PanderamaGaming (3)' Application.
Configuration Error
Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.
Parser Error Message: It is an error to use a section registered as allowDefinition='MachineToApplication' beyond application level. This error can be caused by a virtual directory not being configured as an application in IIS.
Source Error:
Line 15: </connectionStrings>
Line 16: <system.web>
Line 17: <membership>
Line 18: <providers>
Line 19: <clear/>
Source File: C:\Users\Minh\Desktop\PanderamaGaming (3)\panderamagaming\web.config Line: 17
Please help me out. I've been struggling on this for over a week now.
This data.gov website gives an OData data export with instructions to use the link http://data.cms.gov/OData.svc/97k6-zzx3
(After Nugeting Install-Package Microsoft.Data.Services.Client version 5.6.1) I attempt to use the full link to "Add Service Reference" to my C# project in either Visual Studio 2012 or Visual Studio 2013, I get There was an error downloading 'http://data.cms.gov/OData.svc/97k6-zzx3/_vti_bin/ListData.svc/$metadata'.
The request failed with HTTP status 404: Not Found. ...
If I truncate the URL to http://data.cms.gov/OData.svc then I get one step further, but still an error The custom tool 'DataServicesCoreClientGenerator' failed. Data service client code-generation failed: Schema specified is not valid. Errors: ... The 'Name' attribute is invalid - the value '97k6-zzx3' is invalid according to its datatype (I suppose since C# identifiers cannot begin with digits)
Is this a bug with data.cms.gov or Visual Studio (etc)? Is there a close workaround?
Thanks!
Try using https://data.cms.gov/OData.svc/$metadata. Code-generation needs metadata, the above URL will provide that.
The URL https://data.cms.gov/OData.svc is the service document, not metadata.
I want to consume a live service in my project but when I tried to add its reference, following error came:
The document at the url https://exdev.www.property24.com/Services/P24ListingService19.asmx was not recognized as a known document type.
The error message from each known type may help you fix the problem:
- Report from 'XML Schema' is 'The root element of a W3C XML Schema should be and its namespace should be 'http://www.w3.org/2001/XMLSchema'.'.
- Report from 'DISCO Document' is 'Discovery document at the URL https://exdev.www.property24.com/Services/P24ListingService19.asmx could not be found.'.
- The document format is not recognized (the content type is 'application/xhtml+xml; charset=utf-8').
- Report from 'WSDL Document' is 'There is an error in XML document (3, 2).'.
- was not expected.
Metadata contains a reference that cannot be resolved: 'https://exdev.www.property24.com/Services/P24ListingService19.asmx'.
Metadata contains a reference that cannot be resolved: 'https://exdev.www.property24.com/Services/P24ListingService19.asmx'.
If the service is defined in the current solution, try building the solution and adding the service reference again.
The Service URL can be browsed that is: https://exdev.www.property24.com/Services/P24ListingService19.asmx
I tried to add that web service reference under "Service References" but that was giving the above error.
The problem was that the Web Service was old so i managed to get its working reference by going to the "Advance" of Service Reference and adding it as "Web Reference".
As Web Reference can cope with old services.
It worked for me, hope it also will work for you!
When adding a web reference or a service reference, visual studio 2010 shows the following error message. Actual wsdl url is http://x.x.x.x:9999/PersonCRUD.asmx?wsdl. I don't know why visual studio tries to download from http://x.x.x.x/PersonCRUD.asmx?wsdl
Metadata contains a reference that cannot be resolved: 'http://x.x.x.x/PersonCRUD.asmx?wsdl'.
There was an error downloading 'http://x.x.x.x/PersonCRUD.asmx?wsdl'.
The request failed with HTTP status 404: Not Found.
Metadata contains a reference that cannot be resolved: 'http://x.x.x.x:9999/PersonCRUD.asmx'.
Metadata contains a reference that cannot be resolved: 'http://x.x.x.x:9999/PersonCRUD.asmx'.
If the service is defined in the current solution, try building the solution and adding the service reference again.
At the end of the wsdl there is the part that contains the wrong urls. I guess it's the source of the problem. (port :9999 is missing)
<wsdl:port name="PersonCRUDSoap" binding="tns:PersonCRUDSoap">
<soap:address location="http://78.186.32.181/PersonCRUD.asmx"/>
</wsdl:port>
<wsdl:port name="PersonCRUDSoap12" binding="tns:PersonCRUDSoap12">
<soap12:address location="http://78.186.32.181/PersonCRUD.asmx"/>
</wsdl:port>
BTW I tried this in a fresh new web site project.
Is there anyone who have a clue why this error occurs?
Thanks.