Exemplo n.º 1
0
        private void LocationCombo_Data()
        {
            ASPxComboBox combo = LocationCombo as ASPxComboBox;

            combo.Columns.Clear();

            combo.Value = "";

            combo.DataSource = POClass.InventSiteLocationTable(WarehouseCombo.Text.ToString());

            ListBoxColumn l_value = new ListBoxColumn();

            l_value.FieldName = "LocationCode";
            combo.Columns.Add(l_value);

            //ListBoxColumn l_text = new ListBoxColumn();
            //l_text.FieldName = "NAME";
            //Location.Columns.Add(l_text);

            //Location.TextField = "NAME";
            combo.ValueField = "LocationCode";
            combo.DataBind();
            combo.TextFormatString = "{0}";
            combo.ClientEnabled    = true;
        }
        protected void LocationCallback_Callback(object sender, CallbackEventArgsBase e)
        {
            Location.Value = "";

            Location.DataSource = POClass.InventSiteLocationTable(Warehouse.Text.ToString());

            ListBoxColumn l_value = new ListBoxColumn();

            l_value.FieldName = "LocationCode";
            Location.Columns.Add(l_value);

            //ListBoxColumn l_text = new ListBoxColumn();
            //l_text.FieldName = "NAME";
            //Location.Columns.Add(l_text);

            //Location.TextField = "NAME";
            Location.ValueField = "LocationCode";
            Location.DataBind();
            Location.TextFormatString = "{0}";
            Location.ClientEnabled    = true;
        }