Dynamicweb 8 Documentation
Delete() Method
Example 

Deletes this instance.
Syntax
'Declaration
 
Public Overloads Sub Delete() 
public void Delete()
Example
class OrderField_EditPage : System.Web.UI.Page
{
    private void DeleteOrderField( OrderField fld )
    {
       if( FieldExists(orderField.SystemName) ) {
           Database.ExecuteNonQuery("ALTER TABLE [EcomOrders] DROP COLUMN [" + orderField.SystemName + "]", "Ecom.mdb")
       }
 
        fld.Delete();
        Dynamicweb.eCommerce.Common.Application.KillOrderLineFields();
    }
}
class MyPage : System.Web.UI.Page
{
   public void DoDeleteAll()
   {
       foreach (OrderField orderField in OrderField.getOrderFields())
       {
           orderField.Delete();
       }
   }
}
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

OrderField Class
OrderField Members
Overload List

Send Feedback