We are trying to bring back prices for items associated with a specific price level but are hitting a wall. We can get base price but we cannot access any other price levels that we have set up
ItemSearchBasic isb = new ItemSearchBasic();
RecordRef acctRef = new RecordRef();
acctRef.type = RecordType.account;
acctRef.typeSpecified = true;
acctRef.internalId = "295"; //Summer Camp Income 41600
SearchMultiSelectField acct = new SearchMultiSelectField();
acct.@operator = SearchMultiSelectFieldOperator.anyOf;
acct.operatorSpecified = true;
RecordRef[] acctArray = new RecordRef[1];
acctArray[0] = acctRef;
isb.account = acct;
isb.account.searchValue = acctArray;
GetAllRecord re = new GetAllRecord();
re.recordType = GetAllRecordType.priceLevel;
re.recordTypeSpecified = true;
GetAllResult res = service.getAll(re);
Record[] records = res.recordList;
PriceLevel priceLevel = new PriceLevel();
for (int i = 0; i < res.recordList.Length; i++)
{
priceLevel = (PriceLevel)records[i];
string s = priceLevel.name;
if (s == "19")
break;
}
// PricingMatrix pm = new PricingMatrix(); //something like this?
// Pricing p = new Pricing();
// p.priceLevel = priceLevel;
//// this filters just base prices
//SearchDoubleField pr = new SearchDoubleField();
//pr.@operator = SearchDoubleFieldOperator.notEmpty;
//pr.operatorSpecified = true;
//isb.price = pr;
////
SearchResult Response = service.search(isb);
if (Response.recordList.Length > 360)
Any suggestions would be appreciated...