Example #1
0
        public Items(string CodeItem)
        {
            ItemsTable st  = new ItemsTable();
            DataRow    row = st.Find("CodeItem", CodeItem);

            this.NameItem = row["NameItem"].ToString();
            this.PictureItemDescription = row["PictureItemDescription"].ToString();
            this.MinItem    = row["MinItem"].ToString();
            this.PriceItem  = row["PriceItem"].ToString();
            this.Status     = Convert.ToBoolean(row["Status"]);
            this.SeasonItem = row["SeasonItem"].ToString();
            this.SaleItem   = Convert.ToBoolean(row["SaleItem"]);
        }
Example #2
0
        public DataRow BuildRow()
        {
            ItemsTable st     = new ItemsTable();
            DataTable  colTbl = st.Dt;
            DataRow    newRow = colTbl.NewRow();

            newRow["CodeItem"] = this.CodeItem;
            newRow["NameItem"] = this.NameItem;
            newRow["PictureItemDescription"] = this.PictureItemDescription;
            newRow["MinItem"]    = this.MinItem;
            newRow["PriceItem"]  = this.PriceItem;
            newRow["Status"]     = this.Status;
            newRow["SeasonItem"] = this.SeasonItem;
            newRow["SaleItem"]   = this.SaleItem;

            return(newRow);
        }