quickbooks - How to write ItemQuery using ListIdSet? -


i have requirement retrive item information multiple ids, using itemquery same using below code,but gives error "{"invalid or missing value of choice identifier 'itemselementname' of type 'intuit.ipp.data.qbd.itemschoicetype4[]'."}".

please suggest if having idea how use listidset itemquery .

list<intuit.ipp.data.qbd.idtype> ids = new list<intuit.ipp.data.qbd.idtype>();         ids.add(new intuit.ipp.data.qbd.idtype() { value = "123460", iddomain = intuit.ipp.data.qbd.iddomainenum.ng });         ids.add(new intuit.ipp.data.qbd.idtype() { value = "789100", iddomain = intuit.ipp.data.qbd.iddomainenum.ng });         ids.add(new intuit.ipp.data.qbd.idtype() { value = "111213", iddomain = intuit.ipp.data.qbd.iddomainenum.ng });            intuit.ipp.data.qbd.itemquery qbdquery = new intuit.ipp.data.qbd.itemquery();         list<intuit.ipp.data.qbd.item> itemqueryresult = null;         qbdquery.items = ids.toarray();         qbdquery.itemselementname = new itemschoicetype4[] { itemschoicetype4.listidset};         itemqueryresult = qbdquery.executequery<intuit.ipp.data.qbd.item>(context).tolist<intuit.ipp.data.qbd.item>(); 

regards,

reshma d.

here example

itemquery qbditemquery = new itemquery(); qbditemquery.items = new object[] { new idset() { id = new idtype[] { new idtype() { iddomain = iddomainenum.ng, value = "79841" } } } }; qbditemquery.itemselementname = new itemschoicetype4[] { itemschoicetype4.listidset }; list<item> itemqueryresult = qbditemquery.executequery<item>(context).tolist<item>(); 

Comments

Popular posts from this blog

monitor web browser programmatically in Android? -

Shrink a YouTube video to responsive width -

wpf - PdfWriter.GetInstance throws System.NullReferenceException -