Page 1 of 1

Sequence contains no elements

Posted: Thu Aug 11, 2022 4:38 am
by thomassdila
We are getting "Sequence. contains no elements" or "fields not able to add" error in Softpro

{"Sequence contains no elements"}
at SoftPro.ClientModel.Proxies.FaultTolerantClientChannel`1.HandleFaultException(FaultException exception)
at SoftPro.ClientModel.Proxies.FaultTolerantClientChannel`1.InvokeCall(String action, Object[] args)
at SoftPro.OrderTracking.Client.Orders.OrderStoreServiceClient.OpenOrder(OrderIdentifier id, OrderEditMode mode, Boolean exclusiveLock)
at SoftPro.OrderTracking.Client.Orders.OrderStore.OpenOrder(OrderIdentifier id, OrderEditMode mode, Boolean exclusiveLock)
at SoftPro.OrderTracking.Client.Orders.OrderStore.SoftPro.OrderTracking.Client.Orders.IOrderStore.OpenOrder(IOrderInfo orderInfo, OrderEditMode mode, Boolean exclusiveLock)
at SoftPro.OrderTracking.Client.Orders.OrderStore.SoftPro.OrderTracking.Client.Orders.IOrderStore.OpenOrder(IOrderInfo orderInfo, OrderEditMode mode)

Re: Sequence contains no elements

Posted: Thu Aug 11, 2022 10:39 am
by BobRichards
There is insufficient information provided to begin analyzing the issue. What version of Select are you using? Does the code work with some orders but not others? Does it ever work? Are the parameters to IOrderStore.OpenOrder() valid? Can it connect to the Select server correctly? Can you open the order using the Select application with the same user account?

Sorry. In the example you provided, all I can tell is it appears a LINQ expression failed somewhere during the opening of the order in the client-side code. When the code was attempting to connect to the server, the WCF connection failed. It seems likely that some error occurred when attempting to open a connection to the server.