calling a web service from asp.net/vb without visual studio
Posted on 2004-08-12
Our online application needs to consume a web service to implement a GIS system.
We do not use Visual Studio.
Using Web Matrix, I followed the simple process of simply typing in the URL of the WSDL of the service, giving it a namespace to refer to (let's say, 'mapTest'), creating the proxy dll, dropping it into the /bin directory; then I tried to call its methods from the appropriate ASP.Net page.
However, when I attempt to call a method (the only one of interest is 'getMaps()', I always get the following error: "getMaps() is not a member of mapTest."
I've tried this with the dll, using a codebehind file of the vb source, and et cetera. I have no idea what the problem is. I guess I'm lost with all the 'Namespace' junk. There's a class defined in the vb file of course, but I'm confused as to where or how I should bring the code into being available from the aspx file. I've tried using the <%@import namespace%> directive, but I don't know what to put in there. I also tried putting an 'inherits' attribute in the page declaration and using the vb file Web Matrix generated; but after getting the syntax correct after much trial and error, I end up with the same error: 'getMaps() is not a member of mapTest'.
I was under the impression that the dll file generated by Web Matrix (or whatever compiler you use) was supposed to encapsulate the interface with the web service and simply expose the methods available. But after dropping the generated dll into /bin and calling getMaps() by itself, I get the error "getMaps() is not declared". If I qualify the getMaps() function call with the namespace I used when generating the dll - this amounts to mapTest.getMaps() - then I'm back to the original error, that getMaps is not a mamber of mapTest.
I'm obviously not getting anywhere, so any input is appreciated. I may give extra points if the solution is quick, complete and correct! Thanks in advance!