Иногда метод AP301000GetSchema возвращает нуль в DocumentDetails.Я ценю, если у кого-то есть решение.
static void Main(string[] args)
{
ScreenSoapClient WsAcumaticaBA = null;
try
{
WsAcumaticaBA = new ScreenSoapClient(new BasicHttpBinding(BasicHttpSecurityMode.Transport) { AllowCookies = true, MaxReceivedMessageSize = 65536 * 4 }, new EndpointAddress(@"https://acumatica.xxxx.com/Soap/ACUAPWEBSERVICE.asmx"));
if (WsAcumaticaBA != null)
{
LoginResult AcuLoginResult = WsAcumaticaBA.Login(string.Format("{0}@{1}", "username", "tenant"), "password");
if (AcuLoginResult != null && AcuLoginResult.Code == ErrorCode.OK)
{
Console.WriteLine(string.Format("Code: {0} - Session: {1}", AcuLoginResult.Code, AcuLoginResult.Session));
AP301000Content AcuAP301000Content = WsAcumaticaBA.AP301000GetSchema();
Console.WriteLine(string.Format("AcuAP301000Content: {0} - DocumentSummary: {1} - DocumentDetails: {2}", AcuAP301000Content != null ? "OK" : "NULL", AcuAP301000Content.DocumentSummary != null ? "OK" : "NULL", AcuAP301000Content.DocumentDetails != null ? "OK" : "NULL"));
}
}
}
}
Иногда AcuAP301000Content.DocumentDetails имеет значение null.
Спасибо