问题
Well, 'm using SapConnector dll to make RFC from .Net to SAP. When I use dll in a Windows form application, everything is fine, but when I try to make connection in ASP.Net Web Site or Web Applcation a get an error;
Bad Variant Type
if (Connector.StartConnection())
{
try
{
Connector.AddFunction("Z_SCL_SOMETHING");
Connector.AddFunctionInputParameter("WPERNR", "999999");
Connector.CallFunction();
}
}
I get the error in this line;
Connector.AddFunction("Z_SCL_SOMETHING");
Another weird case is that, in Windows Forms Application when I make this call in backgroundWorker I get the same error again.
Any idea about this error ?
来源:https://stackoverflow.com/questions/14454574/sap-rfc-connection-bad-variant-type