Dynamicweb 8 Documentation
GetOrderLinesByOrder Method
Example 

The order.
Gets the order lines.
Syntax
'Declaration
 
Public Shared Function GetOrderLinesByOrder( _ 
   ByVal order As Order _ 
) As OrderLineCollection
public static OrderLineCollection GetOrderLinesByOrder( 
   Order order 
)

Parameters

order
The order.
Example
class MyPage : System.Web.UI.Page
{
 
    public double CalcOrderTotalValue(Order order)
    {
       OrderLineCollection orderLines = OrderLines.GetOrderLinesByOrder(order);
       double V = 0.0;
       if (orderLines.Count > 0)
       {
           foreach (OrderLine ol in orderLines)
           {
		          if (! (ol.Product.Type == ProductType.Service))
		          {
			          V += ol.Volume;
		          }
           }
        }
        return V;
    }
 
}
Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

OrderLine Class
OrderLine Members

Send Feedback