我正在尝试使用远程 API 从 Catalook 中提取订单。这是我的代码:
CATALooKRemote.RemoteController remote = new CATALooKRemote.RemoteController();
remote.Url = "http://localhost/Customers/DotNetNuke_Community_06.02.04_Install/DesktopModules/CATALooKStore/remote.asmx";
bool log = remote.Login(0, "host", "dnnhost");
Response.Write(log);
var orders = remote.GetOrders(new DateTime(2009, 1, 1), new DateTime(2014, 1, 1), -1);
foreach (var a in orders)
{
}
//throws null reference exception
Response.Write(orders.Count());
我的系统中只有一个订单,但是我无法使用这种方法查询它。订单已付款状态。