D
Daryl Davis
I had this working once apon a time before my code was obliterated....
This is a simple dll hosted on a server that goes to a database and returns
the next available number.
I am wrapping it into a webservice so that I can use handheld devices.
the error I get is
Run-time exception thrown : System.NullReferenceException - Object reference
not set to an instance of an object.
when I call the function.
if I set ref = hallcallermain.clscallermain the error is
"System.InvalidCastException: Specified cast is not valid.
when it try's to create object.
any ideas? (code below)
<WebMethod(Description:="Goes to server and returns next available number")>
_
Public Overridable Function GetNextComNumber() As Integer
Dim ref As Object
Try
ref = CreateObject("hallcallermain.clscallermain", "\\192.168.10.254")
Catch ex As Exception
Return 0
End Try
Return ref.GetNextComNumber
End Function
This is a simple dll hosted on a server that goes to a database and returns
the next available number.
I am wrapping it into a webservice so that I can use handheld devices.
the error I get is
Run-time exception thrown : System.NullReferenceException - Object reference
not set to an instance of an object.
when I call the function.
if I set ref = hallcallermain.clscallermain the error is
"System.InvalidCastException: Specified cast is not valid.
when it try's to create object.
any ideas? (code below)
<WebMethod(Description:="Goes to server and returns next available number")>
_
Public Overridable Function GetNextComNumber() As Integer
Dim ref As Object
Try
ref = CreateObject("hallcallermain.clscallermain", "\\192.168.10.254")
Catch ex As Exception
Return 0
End Try
Return ref.GetNextComNumber
End Function