Dynamicweb 8 Documentation
StockGroupID Property (Product)
Example 

Gets or sets StockGroupID.
Syntax
'Declaration
 
Public Property StockGroupID As String
public string StockGroupID {get; set;}
Example
class MyPage : System.Web.UI.Page
{
   protected System.Web.UI.WebControls.DropDownList StockGroupID;
   private Product product;
   public void CreateDropDown()
   {
       SortedList stocklist = new SortedList();
       StockGroupCollection stocks = Dynamicweb.eCommerce.Common.Application.StockGroups;
       foreach (StockGroup stock in stocks)
       {
           if (stock.ID != null)
           {
               stocklist[Convert.ToString(stock.ID)] = stock.Name;
           }
        }
       product.StockGroupID = Base.ChkString(Base.Request("StockGroupID"));
       Dynamicweb.eCommerce.Common.Gui.CreateDropDown(stocklist, StockGroupID, product.StockGroupID);
   }
}
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

Product Class
Product Members

Send Feedback