Visual Basic .NET » Smart Device Application
Web service in ASP.NET 2.0 -- Nilukshi Tharanga Ekanaya --


Hi all,


I have a small problem. Hope you can help me with it. I have a ASP.NET 1.x soution which consists of a web application and a web service. I have converted it to ASP.NET 2.0 using WAP. And now when I try to run my web services, the following erorr appears:


"ERROR The requested URL could not be retrieved"


But when I build me web service project, it gives me no errors.


Thank you very much in advance.


Regards,


MSN Messenger Download today it's FREE!



-- Raj --


Did you try type url in browser and check if it is correct ? like
http://localhost/youWSName/Service1.asmx 
?

Coz what happens when you build and run your project in 2005 it opens up new port.

Try and deploy it on your local machine first and then try the url ....
probably that would help ...

Let me know if you not looking for this...

Raj

-- Nilukshi Tharanga Ekanaya --


Thanks, Raj! I will try doing it and let you know if it works.


regards,






From: "Raj" <vimaljani>
Reply-To: DotNetDevelopment
To: "DotNetDevelopment, VB.NET, C# .NET, ADO.NET, ASP.NET, XML, XML Web Services,.NET Remoting" <DotNetDevelopment>
Subject:
http://localhost/youWSName/Service1.asmx 
?
>
>Coz what happens when you build and run your project in 2005 it opens
>up new port.
>
>Try and deploy it on your local machine first and then try the url ....
>probably that would help ...
>
>Let me know if you not looking for this...
>
>Raj
>
>
>


-- Nilukshi Tharanga Ekanaya --


Hi Raj,


I just tried what you told me to do. Well, it gives me the same error.


Regards,






From: "Raj" <vimaljani>
Reply-To: DotNetDevelopment
To: "DotNetDevelopment, VB.NET, C# .NET, ADO.NET, ASP.NET, XML, XML Web Services,.NET Remoting" <DotNetDevelopment>
Subject:
http://localhost/youWSName/Service1.asmx 
?
>
>Coz what happens when you build and run your project in 2005 it opens
>up new port.
>
>Try and deploy it on your local machine first and then try the url ....
>probably that would help ...
>
>Let me know if you not looking for this...
>
>Raj
>
>
>


-- Nilukshi Tharanga Ekanaya --


Hi!


Thanks Jamie. I published the Web service and now it is working fine. But now, I have a new problem. When I run my Web application which consist of the web reference of the previously mentioned Web service, I get the follwing error,


"Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.

Compiler Error Message: CS0433: The type 'Doctracker.DocumentWS.DocumentService' exists in both 'c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\doctracker\2423ec03\949d403c\App_WebReferences.uhaj8ino.dll' and 'c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\doctracker\2423ec03\949d403c\assembly\dl3\4ff1f93f\a6901089_d0a0c601\Doctracker.DLL'

Source Error:








Line 13:         #region Declaring web service object Line 14:
Line 15: public DocumentWS.DocumentService docTracker = new DocumentWS.DocumentService();
Line 16:
Line 17: #endregion



Source File: c:\Inetpub\wwwroot\Doctracker\App_Code\BLL\IProxy.cs    Line: 15".


Please, could you help me with it.


Thank you in advance.


Regards,






From: "Jamie Fraser" <jamie.fraser>
Reply-To: DotNetDevelopment
To: DotNetDevelopment
Subject:
http://localhost 
/...
>
>Where 1103 is a random port. You should either publish the WS to IIS
>on your local machine, or run the webservice via VS2005, make a note
>of the port number, and then put this correct URL into your client
>app.
>
>On 06/07/06, Nilukshi Tharanga Ekanayake <chootikka> wrote:
> >
> >
> >
> >
> >
Hi Raj,
> >
> > I just tried what you told me to do. Well, it gives me the same error.
>
>


-- "Bradley, Peter" --

The problem is that you have defined the Doctracker.DocumentWS.DocumentService in two files - once in your Web Service and once in your Doctracker assembly. The compiler does not know which version to use. They may both be identical, but the compiler doesn't know that.



You need to get rid of one of the definitions.



I used to get this problem when I used soapsuds to create metadata proxies for .NET remoting. This is because, by default, soapsuds will produce definitions in the metadata for all the referenced objects. The answer was to use soapsuds -gc. This creates separate metadata source
(*.cs) files for each object. A project can be created for the correct one and the metadata source file added to the project. Once the metadata project is compiled, it can be referenced via the Project tab in the Add reference dialog.



If you want more details about this I'll have to look up my documentation. The paragraph above is just a summary of what I remember: but if it looks helpful, I'll look it up for you.



Cheers





Peter




-- Nilukshi Tharanga Ekanaya --


Thank you very much for the information. Like you said, there are 2 AssemblyInfo classes in my solution. Which 1 do you think I should get rid of, the 1 in the Web application or the in the Web service?


Regards,






From: "Bradley, Peter" <pbradley>
Reply-To: DotNetDevelopment
To: <DotNetDevelopment>
Subject:
Re: Web service in ASP.NET 2.0
Date: Thu, 6 Jul 2006 09:20:32 +0100










The problem is that you have defined the Doctracker.DocumentWS.DocumentService in two files – once in your Web Service and once in your Doctracker assembly.  The compiler does not know which version to use.  They may both be identical, but the compiler doesn’t know that.


 


You need to get rid of one of the definitions.


 


I used to get this problem when I used soapsuds to create metadata proxies for .NET remoting.  This is because, by default, soapsuds will produce definitions in the metadata for all the referenced objects.  The answer was to use soapsuds –gc.  This creates separate metadata source (*.cs) files for each object.  A project can be created for the correct one and the metadata source file added to the project.  Once the metadata project is compiled, it can be referenced via the Project tab in the Add reference dialog.


 


If you want more details about this I’ll have to look up my documentation.  The paragraph above is just a summary of what I remember: but if it looks helpful, I’ll look it up for you.


 


Cheers


 


 


Peter


 







From: DotNetDevelopment

Re: Web service in ASP.NET 2.0


 



Hi!


Thanks Jamie. I published the Web service and now it is working fine. But now, I have a new problem. When I run my Web application which consist of the web reference of the previously mentioned Web service, I get the follwing error,


"Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.

Compiler Error Message: CS0433: The type 'Doctracker.DocumentWS.DocumentService' exists in both 'c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\doctracker\2423ec03\949d403c\App_WebReferences.uhaj8ino.dll' and 'c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET
Files\doctracker\2423ec03\949d403c\assembly\dl3\4ff1f93f\a6901089_d0a0c601\Doctracker.DLL'

Source Error:








 

Line 13:         #region Declaring web service object
Line 14:
Line 15:               public DocumentWS.DocumentService docTracker = new DocumentWS.DocumentService();
Line 16:
Line 17:               #endregion


Source File: c:\Inetpub\wwwroot\Doctracker\App_Code\BLL\IProxy.cs    Line: 15".


Please, could you help me with it.


Thank you in advance.


Regards,








From: "Jamie Fraser" <jamie.fraser>
Reply-To: DotNetDevelopment
To: DotNetDevelopment
Subject:

http://localhost 
/...
>
>Where 1103 is a random port. You should either publish the WS to
IIS
>on your local machine, or run the webservice via VS2005, make a note
>of the port number, and then put this correct URL into your client
>app.
>
>On 06/07/06, Nilukshi Tharanga Ekanayake <chootikka> wrote:
> >
> >
> >
> >
> > Hi Raj,
> >
> > I just tried what you told me to do. Well, it gives me the same error.
>
>





-- "Bradley, Peter" --

It's not as straightforward as that.



Please see section 4.2.2.1 of the attached document (assuming the list lets me attach it).



If the list won't accept the attachment, please email me off-list.





Peter




-- Nilukshi Tharanga Ekanaya --


Hi Peter,


Thank you, I received the attachment. And thank you for the help.


Best wishes,






From: "Bradley, Peter" <pbradley>
Reply-To: DotNetDevelopment
To: <DotNetDevelopment>
Subject:
Re: Web service in ASP.NET 2.0
Date: Thu, 6 Jul 2006 10:32:07 +0100










It’s not as straightforward as that.


 


Please see section 4.2.2.1 of the attached document (assuming the list lets me attach it).


 


If the list won’t accept the attachment, please email me off-list.


 


 


Peter


 







From: DotNetDevelopment

Re: Web service in ASP.NET 2.0


 



Thank you very much for the information. Like you said, there are 2 AssemblyInfo classes in my solution. Which 1 do you think I should get rid of, the 1 in the Web application or the in the Web service?


Regards,








From: "Bradley, Peter" <pbradley>
Reply-To: DotNetDevelopment
To: <DotNetDevelopment>
Subject:

Re: Web service in ASP.NET 2.0
Date: Thu, 6 Jul 2006 09:20:32 +0100


The problem is that you have defined the Doctracker.DocumentWS.DocumentService in two files – once in your Web Service and once in your Doctracker assembly.  The compiler does not know which version to use.  They may both be identical, but the compiler doesn’t know that.


 


You need to get rid of one of the definitions.


 


I used to get this problem when I used soapsuds to create metadata proxies for .NET remoting.  This is because, by default, soapsuds will produce definitions in the metadata for all the referenced objects.  The answer was to use soapsuds –gc.  This creates separate metadata source (*.cs) files for each object.  A project can be created for the correct one and the metadata source file added to the project.  Once the metadata project is compiled, it can be referenced via the Project tab in the Add reference dialog.


 


If you want more details about this I’ll have to look up my documentation.  The paragraph above is just a summary of what I remember: but if it looks helpful, I’ll look it up for you.


 


Cheers


 


 


Peter


 







From: DotNetDevelopment

Re: Web service in ASP.NET 2.0


 



Hi!


Thanks Jamie. I published the Web service and now it is working fine. But now, I have a new problem. When I run my Web application which consist of the web reference of the previously mentioned Web service, I get the follwing error,


"Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.

Compiler Error Message: CS0433: The type 'Doctracker.DocumentWS.DocumentService' exists in both 'c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\doctracker\2423ec03\949d403c\App_WebReferences.uhaj8ino.dll' and 'c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET
Files\doctracker\2423ec03\949d403c\assembly\dl3\4ff1f93f\a6901089_d0a0c601\Doctracker.DLL'

Source Error:








 

Line 13:         #region Declaring web service object
Line 14:
Line 15:               public DocumentWS.DocumentService docTracker = new DocumentWS.DocumentService();
Line 16:
Line 17:               #endregion


Source File: c:\Inetpub\wwwroot\Doctracker\App_Code\BLL\IProxy.cs    Line: 15".


Please, could you help me with it.


Thank you in advance.


Regards,








From: "Jamie Fraser" <jamie.fraser>
Reply-To: DotNetDevelopment
To: DotNetDevelopment
Subject:

http://localhost 
/...
>
>Where 1103 is a random port. You should either publish the WS to
IIS
>on your local machine, or run the webservice via VS2005, make a note
>of the port number, and then put this correct URL into your client
>app.
>
>On 06/07/06, Nilukshi Tharanga Ekanayake <chootikka> wrote:
> >
> >
> >
> >
> > Hi Raj,
> >
> > I just tried what you told me to do. Well, it gives me the same error.
>
>





><< Creatingandusingremoteobjects(metadataproxy).pdf >>



Don't just search. Find. MSN Search Check out the new MSN Search!



-- Jamie Fraser --


I presume when you were using .net 1.1, the WebService was accessed like

http://localhost 
/.....

But now it will be accessed like

http://localhost:1103 
/...

Where 1103 is a random port. You should either publish the WS to IIS on your local machine, or run the webservice via VS2005, make a note of the port number, and then put this correct URL into your client app.

On 06/07/06, Nilukshi Tharanga Ekanayake wrote:


Hi Raj,

I just tried what you told me to do. Well, it gives me the same error.
 

[Submit Comment]Home