How to define paramter-types for WebMethods AND Client?

D

Daniel Barisch

How to define a class within an external DLL, that can be used as parameter
for a WebMethod and in Client-Projects?

I mean:

<WebService()>
public Class WServer
<WebMethod()>_
Public Function getXYZ(myDataSet as System.DataDataSet) as xyz...
....
end class

= Client =
....
dim ws as new WebServiceProxy.WServer
dim ds as new System.Data.DataSet
dim rc as xyz
rc = ws.getXYZ(ds)

That works fine. But changing the type of "ds" to a class defined in an
external DLL (reference in WebService- and client-project) the following
happens ...

<WebMethod()>_
Public Function getXYZ(myClass As ExternalDLL.MyClass) as xyz ...

dim ws as new WebServiceProxy.WServer
dim ds as new ExterneDLL.MyClass
dim rc as xyz
rc = ws.getXYZ(ds)
"WebServiceProxy.MyClass"!' (paramter "ds")

How to get the client clear, that it is exactly the same class? Is there
something special, I have to define in "ExternalDLL.MyClass"
(serialisation)?

Thanks D.Barisch
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top