Code to Dump an Order Form

Use the following code to dump the contents of an order form. The code sample should be used within a Commerce Server project. For more information about creating a Commerce Server project, see Creating a Commerce Project.

using Microsoft.CommerceServer.Runtime;
// For Idictionary.
using Microsoft.CommerceServer.Runtime.Orders;
// For OrderForm.
using Microsoft.CommerceServer.Runtime.Diagnostics;
   // For DumpUtils.

   OrderForm orderForm = basket.OrderForms[0];
   DumpUtils.DumpDictionary(orderForm.Dictionary, new HtmlTextWriter(Response.Output), "OrderForm: " + orderForm.Name);

See Also

Dictionary Class (BCL)

DumpUtils Class (BCL)

OrderForm Class (BCL)

Copyright © 2005 Microsoft Corporation.
All rights reserved.