コード例 #1
0
        public Item_Template(PartData Part)
        {
            InitializeComponent();
            try
            {
                //Use Part to fill data fields

                Partnumber_txt.Text = Part.PartNumber;

                Description_txt.Text = Part.Description;

                type_cbo.SelectedIndex = type_cbo.Items.IndexOf(Part.PMT);

                NetWeight.Value = Part.Net_Weight;

                NetVolume.Value = Part.Net_Vol;

                group_cbo.SelectedIndex = group_cbo.Items.IndexOf(Part.PartGroup);

                class_cbo.SelectedIndex = class_cbo.Items.IndexOf(Part.PartClass);
            }
            catch (Exception ex)
            {
                MessageBox.Show("Error importing data fields.  Default values will show.\n" + ex.Message, "Error!", MessageBoxButtons.OK, MessageBoxIcon.Warning);
            }
        }
コード例 #2
0
        public Item_Master(PartData Part)
        {
            InitializeComponent();
            try
            {
                //Use Part to fill data fields

                Partnumber_txt.Text = Part.PartNumber;

                Description_txt.Text = Part.Description;

                type_cbo.SelectedIndex = type_cbo.Items.IndexOf(Part.PMT);

                NetWeight.Value = Part.Net_Weight;

                userevision.Checked = Part.UseRevision;

                qtybearing.Checked = Part.QtyBearing;

                trackserial.Checked = Part.TrackSerial;

                //NetVolume.Value = Part.Net_Vol;

                group_cbo.SelectedIndex = group_cbo.Items.IndexOf(Part.PartGroup);

                class_cbo.SelectedIndex = class_cbo.Items.IndexOf(Part.PartClass);
            }
            catch (Exception ex)
            {
                MessageBox.Show("Error importing data fields.  Default values will show.\n" + ex.Message, "Error!", MessageBoxButtons.OK, MessageBoxIcon.Warning);
            }
        }
コード例 #3
0
        public Item_Template(PartData Part)
        {
            InitializeComponent();
            try
            {
                //Use Part to fill data fields

                Partnumber_txt.Text = Part.PartNumber;

                Description_txt.Text = Part.Description;

                type_cbo.SelectedIndex = type_cbo.Items.IndexOf(Part.PMT);

                NetWeight.Value = Part.Net_Weight;

                NetVolume.Value = Part.Net_Vol;

                group_cbo.SelectedIndex = group_cbo.Items.IndexOf(Part.PartGroup);

                class_cbo.SelectedIndex = class_cbo.Items.IndexOf(Part.PartClass);
            }
            catch (Exception ex)
            {
                MessageBox.Show("Error importing data fields.  Default values will show.\n" + ex.Message, "Error!", MessageBoxButtons.OK, MessageBoxIcon.Warning);
            }
        }
コード例 #4
0
        public Item_Master(PartData Part)
        {
            InitializeComponent();
            try
            {
                //Use Part to fill data fields

                Partnumber_txt.Text = Part.PartNumber;

                Description_txt.Text = Part.Description;

                type_cbo.SelectedIndex = type_cbo.Items.IndexOf(Part.PMT);

                NetWeight.Value = Part.Net_Weight;

                userevision.Checked = Part.UseRevision;

                qtybearing.Checked = Part.QtyBearing;

                trackserial.Checked = Part.TrackSerial;

                //NetVolume.Value = Part.Net_Vol;

                group_cbo.SelectedIndex = group_cbo.Items.IndexOf(Part.PartGroup);

                class_cbo.SelectedIndex = class_cbo.Items.IndexOf(Part.PartClass);
            }
            catch (Exception ex)
            {
                MessageBox.Show("Error importing data fields.  Default values will show.\n" + ex.Message, "Error!", MessageBoxButtons.OK, MessageBoxIcon.Warning);
            }
        }
コード例 #5
0
        private void copy_btn_Click(object sender, EventArgs e)
        {
            Item_CopyFrom frm = new Item_CopyFrom();

            PartData pdata = new PartData();

            frm.ShowDialog();

            if (frm.DialogResult == DialogResult.Ignore)
            {
                MessageBox.Show("Item was duplicated successfully.", "Item Duplicated", MessageBoxButtons.OK, MessageBoxIcon.Information);

                this.Close();
            }
            else
            {
                pdata = frm._Pdata;

                LoadData(pdata);
            }
        }
コード例 #6
0
        public Warehouse_Master(PartData _Pdata)
        {
            InitializeComponent();

            Pdata = _Pdata;
        }
コード例 #7
0
        public Warehouse_Master(PartData _Pdata)
        {
            InitializeComponent();

            Pdata = _Pdata;
        }
コード例 #8
0
        private void LoadData(PartData pdata)
        {
            if (pdata.Description != "")
            {
                Description_txt.Text = pdata.Description;
            }

            if (pdata.PMT != "")
            {
                type_cbo.SelectedText = pdata.PMT;
            }

            if (pdata.UOM_Class != "")
            {
                uomclass_cbo.SelectedText = pdata.UOM_Class;
            }

            if (pdata.Net_Weight != 0)
            {
                NetWeight.Value = pdata.Net_Weight;
            }

            if (pdata.Net_Weight_UM != "")
            {
                uomweight_cbo.SelectedText = pdata.Net_Weight_UM;
            }

            if (pdata.TrackSerial != null)
            {
                trackserial.Checked = pdata.TrackSerial;
            }

            if (pdata.QtyBearing != null)
            {
                qtybearing.Checked = pdata.QtyBearing;
            }

            if (pdata.UseRevision != null)
            {
                userevision.Checked = pdata.UseRevision;
            }

            /*if (pdata.Net_Vol != 0)
             *  NetVolume.Value = pdata.Net_Vol;
             *
             * if (pdata.Net_Vol_UM != "")
             *  uomvol_cbo.SelectedText = pdata.Net_Vol_UM;*/

            if (pdata.Primary_UOM != "")
            {
                uom_cbo.SelectedText = pdata.Primary_UOM;
            }

            if (pdata.PartGroup != "")
            {
                group_cbo.SelectedText = pdata.PartGroup;
            }

            if (pdata.PartClass != "")
            {
                class_cbo.SelectedText = pdata.PartClass;
            }

            if (pdata.PartPlant != "")
            {
                plant_cbo.SelectedText = pdata.PartPlant;
            }

            if (pdata.PlantWhse != "")
            {
                whse_cbo.SelectedText = pdata.PlantWhse;
            }
        }
コード例 #9
0
        private void LoadData(PartData pdata)
        {
            if (pdata.Description != "")
                Description_txt.Text = pdata.Description;

            if (pdata.PMT != "")
                type_cbo.SelectedText = pdata.PMT;

            if (pdata.UOM_Class != "")
                uomclass_cbo.SelectedText = pdata.UOM_Class;

            if (pdata.Net_Weight != 0)
                NetWeight.Value = pdata.Net_Weight;

            if (pdata.Net_Weight_UM != "")
                uomweight_cbo.SelectedText = pdata.Net_Weight_UM;

            if (pdata.TrackSerial != null)
                trackserial.Checked = pdata.TrackSerial;

            if (pdata.QtyBearing != null)
                qtybearing.Checked = pdata.QtyBearing;

            if (pdata.UseRevision != null)
                userevision.Checked = pdata.UseRevision;

            /*if (pdata.Net_Vol != 0)
                NetVolume.Value = pdata.Net_Vol;

            if (pdata.Net_Vol_UM != "")
                uomvol_cbo.SelectedText = pdata.Net_Vol_UM;*/

            if (pdata.Primary_UOM != "")
                uom_cbo.SelectedText = pdata.Primary_UOM;

            if (pdata.PartGroup != "")
                group_cbo.SelectedText = pdata.PartGroup;

            if (pdata.PartClass != "")
                class_cbo.SelectedText = pdata.PartClass;

            if (pdata.PartPlant != "")
                plant_cbo.SelectedText = pdata.PartPlant;

            if (pdata.PlantWhse != "")
                whse_cbo.SelectedText = pdata.PlantWhse;
        }
コード例 #10
0
        private void copy_btn_Click(object sender, EventArgs e)
        {
            Item_CopyFrom frm = new Item_CopyFrom();

            PartData pdata = new PartData();

            frm.ShowDialog();

            if (frm.DialogResult == DialogResult.Ignore)
            {
                MessageBox.Show("Item was duplicated successfully.", "Item Duplicated", MessageBoxButtons.OK, MessageBoxIcon.Information);

                this.Close();
            }
            else
            {
                pdata = frm._Pdata;

                LoadData(pdata);
            }
        }