Web serveces

  • Thread starter Thread starter news.online.no
  • Start date Start date
N

news.online.no

Hello

Can someone tel me why My defined object wont work in a WEB servece.
The web servece does not return any XML when TestW is Invoked
<WebMethod()> Public Function TestW() As Returobjekt

TestW.mTest1 = "ABC"

TestW.mTest2 = "DEF"

End Function



' MY Object

Public Class Returobjekt

Public mTest1 As String

Public mTest2 As String

End Class



Regards

Vidar Martinsen
 
Try this instead:

<WebMethod()> Public Function TestW as Returobjekt
Dim ret as new Returobjekt()
ret.mTest1 = "ABC"
ret.mTest2 = "DEF"
Return ret
End Function
 
Back
Top