Cast Problem in Web service proxy
Hi,
I have got a web service which returns a custom object defined in the web service itself. When i use the Web service in a windows form,through a proxy to return the custom object, it gives me the error "Specified Cast not valid". Can anyone help me out?
The problem occurs in the proxy in the following method
public OrderPrintResult StartOrderPrint(string UserLogin, string UserPassword, int LocationID, int SiteID, int WorkQueueID) {
object[] results = this.Invoke("StartOrderPrint", new object[] {
UserLogin,
UserPassword,
LocationID,
SiteID,
WorkQueueID});
return ((OrderPrintResult)(results[0]));
}
The problem occurs when the cast (OrderPrintResult)(results[0]) is made. Please help me out.
This is really important as i am running out of time.
Thanks and Regards
Amit Taparia
|