Hi.
I need to access a remote web service which I have created on the
domain www.abc.net. The web service is working well when used on www.abc.net
and is also accessible through the web browser responding with the
usual WSDL.
For my second domaind (www.abcd.net), I have added the Web Service as
a Web Reference (with Visual Studio, which actually created a new
folder "App_WebReferences" which automatically added a new folder for
each domain in this order: net, abc, www. The "www"-folder contains
discovery files and WSDL files for references to the web service to be
consumed in the site).
The Web Service should therefore be accessible for my dropdownlist
(whis is actually a cascadingDropDown for extra functionality), and my
code (C#) looks like this:
<asp:DropDownList ID="ddl1" runat="server" CssClass="ddl" /
<ajaxToolkit:CascadingDropDown
ID="CascadingDropDown4"
runat="server"
TargetControlID="ddl1"
Category="Category"
PromptText="Choose your type."
ServicePath="http://www.abc.net/Category.asmx"
ServiceMethod="GetCategories" />
So I need to define the correct ServicePath. When used at www.abc.net,
the above is correct. However when I want to use it at my second
domain I have tried two alternatives, giving me different error
messages:
ServicePath="http://www.abc.net/Category.asmx" produces an "Access
denied" error.
ServicePath="http://www.abcd.net/Category.asmx" produces an "Method
Error 500" error.
I tried to set the service path (relative to root) to the generated
folders and files from the adding of the web service as follows:
ServicePath="../App_WebReferences/net/abc/www/Category" produces an
"Method Error 404" error.
ServicePath="../App_WebReferences/net/abc/www/Category.disco" produces
an "Method Error 404" error.
ServicePath="../App_WebReferences/net/abc/www/Category.discomap"
produces an "Method Error 404" error.
ServicePath="../App_WebReferences/net/abc/www/Category.wsdl" produces
an "Method Error 404" error.
I should add that I have copied the Category.cs-file (which generates
an .asmx-file by the server/visual at root of domain) to the second
domain for test purposes. This gave me the "Method Error 500"-error.
Hope you might help me.
Please let me know if I should add additional information to make it
easier for you to help me.
Best regards,
Royend
Peter Bromberg [C# MVP] - 16 Feb 2008 22:24 GMT
Royend,
this is not really a C# language group question. You can try the ASP.NET
newsgroup, or better yet, the AJAX forums on the ASP.NET site.
-- Peter
Site: http://www.eggheadcafe.com
UnBlog: http://petesbloggerama.blogspot.com
MetaFinder: http://www.blogmetafinder.com
> Hi.
> I need to access a remote web service which I have created on the
[quoted text clipped - 54 lines]
> Best regards,
> Royend