I have used the example and retrieved the purchases and they contain things like OrderGroupId, SoldToId, SoldToAddressId, total, etc. I would like to get the actual address of who it was sold to, the contents of each line item, and the credit card information (type, number etc). It seems that with the ordergroupid, and the addressid I should be able to grab other types of information, and I can see it in the DB, but how do I grab the data through the API
thanks!

getting more info from purchase orders
UltimateSniper
You can use the GetPurchaseOrderAsDataSet method (on PurchaseOrderManager class - so it is on the management API side) to get all this information in a dataset. On the runtime you can load the PO as a PurchaseOrder but only if you know the UserId - that should then give you complete access to all this information on the runtime side as well.
Hope that helps.
Nihit
Mark Benningfield
Read here: http://msdn2.microsoft.com/en-us/library/aa546039.aspx
Patrick
Clinic332050
What I ended up doing first creating a PurchaseOrderManager object named 'manager' then :
DS = manager.GetPurchaseOrderAsDataSet(new Guid(g));
('g' is OrderGroupId from the dataset returned by SearchPurchaseOrders
)
and from the the following extracted the credit card identifier from the purchase order:
DS.Tables[
"Payments.CreditCardPayment"].Rows[0]["CreditCardIdentifier"].ToString()passed that value to a function that did the following:
1) got a ProfileManagementContext
2) created a search clause:
SearchClauseFactory factory =profile.GetSearchClauseFactory(searchableEntities,
"CreditCard");searchClause =
factory.CreateClause(
ExplicitComparisonOperator.Equal, "id", "{" + ccid + "}" );(note: ccid is creditcardidenitfier from above)
thanks for your help, more examples on the microsoft site would be helpful.
Taegello
Thank you, that does help a grea deal...but it leads into another question. I see the Payments.CreditCardPayment table has a field called CreditCardNumber, but it leaves it blank, where can I grab the credit card number from
thanks