예제 #1
0
        /*public bool OnlyShowOwedCommissioners
         * {
         *  get
         *  {
         *      return bShowingOnlyOwed;
         *  }
         *  set
         *  {
         *      lbCode.Items.Clear();
         *      lbName.Items.Clear();
         *      string[] sCodes = sEngine.GetListOfCommissioners();
         *      for (int i = 0; i < sCodes.Length; i++)
         *      {
         *          if ((sEngine.GetCommissionerAmountOwed(sCodes[i]) != 0 && value) || !value)
         *          {
         *              lbCode.Items.Add(sCodes[i]);
         *              lbName.Items.Add(sEngine.GetCommissionerName(sCodes[i]));
         *          }
         *      }
         *
         *      if (lbCode.Items.Count > 0)
         *          lbCode.SelectedIndex = 0;
         *  }
         * }*/

        public frmListOfCommissioners(ref StockEngine se)
        {
            sEngine           = se;
            this.AllowScaling = false;

            this.Size            = new Size(280, 300);
            this.FormBorderStyle = FormBorderStyle.FixedToolWindow;

            AddMessage("INST", "Press Insert to add or edit a commissioner.", new Point(10, 10));


            lbCode                       = new CListBox();
            lbCode.Location              = new Point(10, BelowLastControl);
            lbCode.Size                  = new Size(60, this.Height - 65);
            lbCode.BorderStyle           = BorderStyle.None;
            lbCode.KeyDown              += new KeyEventHandler(lbKeyDown);
            lbCode.SelectedIndexChanged += new EventHandler(lbSelChanged);
            this.Controls.Add(lbCode);

            lbName                       = new CListBox();
            lbName.Location              = new Point(lbCode.Left + lbCode.Width, lbCode.Top);
            lbName.Size                  = new Size(200, this.Height - 65);
            lbName.BorderStyle           = BorderStyle.None;
            lbName.KeyDown              += new KeyEventHandler(lbKeyDown);
            lbName.SelectedIndexChanged += new EventHandler(lbSelChanged);
            this.Controls.Add(lbName);

            LoadCommissioners();

            this.Text = "Select a Commissioner";
        }
예제 #2
0
        public AutoCompleteTextBox()
        {
            // Create the form that will hold the list
            this.popup = new Form();
            this.popup.StartPosition   = FormStartPosition.Manual;
            this.popup.ShowInTaskbar   = false;
            this.popup.FormBorderStyle = FormBorderStyle.None;
            this.popup.TopMost         = true;
            this.popup.Deactivate     += new EventHandler(Popup_Deactivate);

            // Create the list box that will hold mathcing items
            this.list        = new CListBox();
            this.list.Cursor = Cursors.Hand;
            //this.list.BorderStyle = BorderStyle.None;
            this.list.SelectedIndexChanged += new EventHandler(List_SelectedIndexChanged);
            this.list.MouseDown            += new MouseEventHandler(List_MouseDown);
            //this.list.ItemHeight = 14;
            this.list.DrawMode  = DrawMode.OwnerDrawFixed;
            this.list.DrawItem += new DrawItemEventHandler(List_DrawItem);
            this.list.Dock      = DockStyle.Fill;

            // Add the list box to the popup form
            this.popup.Controls.Add(this.list);

            // Add default triggers.
            this.triggers.Add(new TextLengthTrigger(1));
            this.triggers.Add(new ShortCutTrigger(Keys.Enter, TriggerState.SelectAndConsume));
            this.triggers.Add(new ShortCutTrigger(Keys.Tab, TriggerState.Select));
            this.triggers.Add(new ShortCutTrigger(Keys.Control | Keys.Space, TriggerState.ShowAndConsume));
            this.triggers.Add(new ShortCutTrigger(Keys.Escape, TriggerState.HideAndConsume));
        }
예제 #3
0
        public frmCategoryEdit(ref StockEngine se)
        {
            sEngine = se;

            AllowScaling = false;

            lbListOfCodes             = new CListBox();
            lbListOfCodes.Location    = new Point(10, 10);
            lbListOfCodes.BorderStyle = BorderStyle.None;
            lbListOfCodes.Size        = new Size((this.Width / 3) - 30, this.Height - 200);
            this.Controls.Add(lbListOfCodes);

            lbListOfCategories             = new CListBox();
            lbListOfCategories.Location    = new Point(lbListOfCodes.Left + lbListOfCodes.Width, 10);
            lbListOfCategories.BorderStyle = BorderStyle.None;
            lbListOfCategories.Size        = new Size((this.Width / 2) - 30, this.Height - 200);
            this.Controls.Add(lbListOfCategories);

            AddMessage("INST1", "Insert key to add a category, Enter to edit the selected one, Esc to exit.", new Point(10, BelowLastControl));

            this.FormBorderStyle = FormBorderStyle.FixedToolWindow;
            this.StartPosition   = FormStartPosition.CenterScreen;
            this.Size            = new Size(815, 640);

            ListAllCategories();
            lbListOfCodes.Focus();
            lbListOfCodes.KeyDown += new KeyEventHandler(lbListOfCodes_KeyDown);
            lbListOfCodes.SelectedIndexChanged += new EventHandler(lbListOfCodes_SelectedIndexChanged);
            lbListOfCodes.SelectedIndex         = 0;

            this.Text = "Category Edit";
        }
        public frmListOfItemTypes()
        {
            this.FormBorderStyle = FormBorderStyle.FixedToolWindow;
            this.AllowScaling    = false;
            this.Text            = "Item Type";
            this.Size            = new Size(170, 190);

            AddMessage("INST", "Select an Item Type", new Point(10, 10));

            lbItemType             = new CListBox();
            lbItemType.Location    = new Point(10, BelowLastControl);
            lbItemType.Size        = new Size(this.ClientSize.Width - 20, this.ClientSize.Height - 10 - lbItemType.Top);
            lbItemType.BorderStyle = BorderStyle.FixedSingle;
            this.Controls.Add(lbItemType);

            lbItemType.Items.Add("1. Stock Item");
            lbItemType.Items.Add("2. Department Item");
            lbItemType.Items.Add("3. Non-Stock Item");
            lbItemType.Items.Add("4. Multi-item Item");
            lbItemType.Items.Add("5. Child of Stock Item");
            lbItemType.Items.Add("6. Commission Item");

            lbItemType.KeyDown      += new KeyEventHandler(lbItemType_KeyDown);
            lbItemType.SelectedIndex = 0;
        }
예제 #5
0
    /// <summary>
    /// US:1945 US:1880 search the list of note titles
    /// </summary>
    /// <param name="sender"></param>
    /// <param name="e"></param>
    protected void btnSearchOptions_Click(object sender, EventArgs e)
    {
        //re-load the note titles
        lbNoteTitles.Items.Clear();

        CNoteTitleData ntd          = new CNoteTitleData(BaseMstr.BaseData);
        DataSet        dsNoteTitles = null;
        CStatus        status       = ntd.GetNoteTitleDS(out dsNoteTitles);

        if (!status.Status)
        {
            ShowStatusInfo(status);
            return;
        }

        lbNoteTitles.DataTextField = "note_title_label";
        //note: the tag is not unique so it cannot be used
        //as the datavaluefield, will map incorrectly...
        //lbNoteTitles.DataValueField = "note_title_tag";
        lbNoteTitles.DataValueField = "note_title_label";
        lbNoteTitles.DataSource     = dsNoteTitles;
        lbNoteTitles.DataBind();

        //filter the listbox using helper
        CListBox clb = new CListBox();

        clb.FilterListBox(lbNoteTitles, txtSearchOptions.Text);

        //show the parents MPE and then this controls MPE
        ShowMPE();
    }
예제 #6
0
        public frmCatGroupAddEdit(ref StockEngine se)
        {
            sEngine = se;

            AddMessage("INST", "Insert to add a category group, Shift & Delete to delete a category group. Enter to edit the category group with the same keys.", new Point(10, 10));

            lbListOfCatGroups                       = new CListBox();
            lbListOfCatGroups.Location              = new Point(10, BelowLastControl);
            lbListOfCatGroups.Size                  = new Size(500, this.Height - 60);
            lbListOfCatGroups.SelectedIndexChanged += new EventHandler(lbListOfCatGroups_SelectedIndexChanged);
            lbListOfCatGroups.KeyDown              += new KeyEventHandler(lbListOfCatGroups_KeyDown);
            this.Controls.Add(lbListOfCatGroups);

            lbListOfCatsInGroup          = new CListBox();
            lbListOfCatsInGroup.Location = new Point(520, lbListOfCatGroups.Top);
            lbListOfCatsInGroup.KeyDown += new KeyEventHandler(lbListOfCatsInGroup_KeyDown);
            lbListOfCatsInGroup.Size     = new Size(500, this.Height - 60);
            this.Controls.Add(lbListOfCatsInGroup);

            string[] sItems = sEngine.GetListOfCategoryGroupNames();
            lbListOfCatGroups.Items.AddRange(sItems);
            lbListOfCatGroups.SelectedIndex = 0;
            this.WindowState = FormWindowState.Maximized;

            this.Text = "Add / Edit Category Groups";
        }
예제 #7
0
        public frmReportDates(Period pPeriod)
        {
            this.FormBorderStyle = FormBorderStyle.FixedToolWindow;
            this.Size            = new Size(200, 500);
            AddMessage("HELP", "Date of period end:", new Point(10, 10));
            lbDates             = new CListBox();
            lbDates.Location    = new Point(10, BelowLastControl);
            lbDates.Size        = new Size(this.ClientSize.Width - 20, this.ClientSize.Height - 10 - lbDates.Top);
            lbDates.BorderStyle = BorderStyle.FixedSingle;
            this.Controls.Add(lbDates);
            lbDates.KeyDown += new KeyEventHandler(lbDates_KeyDown);

            string sPeriod = "";

            switch (pPeriod)
            {
            case Period.Daily:
                sPeriod = "Daily";
                break;

            case Period.Monthly:
                sPeriod = "Monthly";
                break;

            case Period.Weekly:
                sPeriod = "Weekly";
                break;

            case Period.Yearly:
                sPeriod = "Yearly";
                break;
            }

            string sDir = "Archive\\" + sPeriod;

            if (Directory.Exists(sDir))
            {
                sDirs = Directory.GetDirectories(sDir);
            }
            else
            {
                sDirs = new string[0];
            }

            for (int i = 0; i < sDirs.Length; i++)
            {
                string sDate       = sDirs[i].Split('\\')[sDirs[i].Split('\\').Length - 1];
                string sDayOfMonth = sDate[8].ToString() + sDate[9].ToString();
                string sMonth      = sDate[5].ToString() + sDate[6].ToString();
                string sYear       = sDate[0].ToString() + sDate[1].ToString() + sDate[2].ToString() + sDate[3].ToString();
                lbDates.Items.Add(sDayOfMonth + "/" + sMonth + "/" + sYear);
            }

            if (lbDates.Items.Count > 0)
            {
                lbDates.SelectedIndex = lbDates.Items.Count - 1;
            }
        }
        public frmWeeklySalesSummary(ref StockEngine se)
        {
            sEngine   = se;
            this.Size = new Size(700, 590);
            this.SurroundListBoxes = true;

            lbWeekNum                       = new CListBox();
            lbWeekNum.Location              = new Point(10, 31);
            lbWeekNum.Size                  = new Size(50, 500);
            lbWeekNum.BorderStyle           = BorderStyle.None;
            lbWeekNum.KeyDown              += new KeyEventHandler(lbLastYear_KeyDown);
            lbWeekNum.SelectedIndexChanged += new EventHandler(lbLastYear_SelectedIndexChanged);
            this.Controls.Add(lbWeekNum);
            AddMessage("WEEK", "Week", new Point(10, 10));

            lbLastYear                       = new CListBox();
            lbLastYear.Location              = new Point(60, 31);
            lbLastYear.Size                  = new Size(150, 500);
            lbLastYear.BorderStyle           = BorderStyle.None;
            lbLastYear.KeyDown              += new KeyEventHandler(lbLastYear_KeyDown);
            lbLastYear.SelectedIndexChanged += new EventHandler(lbLastYear_SelectedIndexChanged);
            lbLastYear.RightToLeft           = RightToLeft.Yes;
            this.Controls.Add(lbLastYear);
            AddMessage("LY", "Last Year", new Point(60, 10));

            lbThisYear                       = new CListBox();
            lbThisYear.Location              = new Point(210, 31);
            lbThisYear.Size                  = new Size(150, 500);
            lbThisYear.BorderStyle           = BorderStyle.None;
            lbThisYear.KeyDown              += new KeyEventHandler(lbLastYear_KeyDown);
            lbThisYear.RightToLeft           = RightToLeft.Yes;
            lbThisYear.SelectedIndexChanged += new EventHandler(lbLastYear_SelectedIndexChanged);
            this.Controls.Add(lbThisYear);
            AddMessage("TY", "This Year", new Point(210, 10));

            lbWeekCommencing                       = new CListBox();
            lbWeekCommencing.Location              = new Point(400, 31);
            lbWeekCommencing.Size                  = new Size(this.ClientSize.Width - 10 - lbWeekCommencing.Left, 500);
            lbWeekCommencing.BorderStyle           = BorderStyle.None;
            lbWeekCommencing.KeyDown              += new KeyEventHandler(lbLastYear_KeyDown);
            lbWeekCommencing.SelectedIndexChanged += new EventHandler(lbLastYear_SelectedIndexChanged);
            this.Controls.Add(lbWeekCommencing);
            AddMessage("WC", "Week Commencing", new Point(360, 10));

            lbAverage          = new Label();
            lbAverage.Location = new Point(lbWeekNum.Left, lbWeekNum.Top + lbWeekNum.Height);
            lbAverage.AutoSize = true;
            this.Controls.Add(lbAverage);

            this.AllowScaling    = false;
            this.FormBorderStyle = FormBorderStyle.FixedToolWindow;
            this.Text            = "Weekly Sales Summary";

            LoadStats();
            //lbWeekNum.SelectedIndex = sEngine.WeekCalc(DateTime.Now.Day.ToString() + "/" + DateTime.Now.Month.ToString() + "/" + DateTime.Now.Year.ToString()) - 1;
        }
예제 #9
0
        public frmListOfSuppliers(ref StockEngine se)
        {
            sEngine = se;
            AddMessage("CODE", "Supplier Code", new Point(10, 10));
            AddMessage("NAME", "Supplier Name", new Point(100, 10));
            AddMessage("EDIT", "Press Insert To Add / Edit A Supplier, Shift+Del to Delete", new Point(10, BelowLastControl));
            this.AllowScaling      = false;
            this.SurroundListBoxes = true;
            this.Size            = new Size(400, 100);
            this.FormBorderStyle = FormBorderStyle.FixedToolWindow;
            this.Text            = "Select A Supplier";

            lbCode             = new CListBox();
            lbCode.Height      = 5;
            lbCode.Location    = new Point(10, BelowLastControl);
            lbCode.BorderStyle = BorderStyle.None;
            this.Controls.Add(lbCode);

            lbName             = new CListBox();
            lbName.Height      = 5;
            lbName.Location    = new Point(100, lbCode.Top);
            lbName.BorderStyle = BorderStyle.None;
            this.Controls.Add(lbName);

            string[] sTillCodes = sEngine.GetListOfSuppliers();
            Array.Sort(sTillCodes);
            for (int i = 0; i < sTillCodes.Length; i++)
            {
                string[] sTillData = sEngine.GetSupplierDetails(sTillCodes[i]);
                lbCode.Items.Add(sTillData[0]);
                lbName.Items.Add(sTillData[1]);
                if (this.Height < 700)
                {
                    lbCode.Height += lbCode.ItemHeight;
                    lbName.Height += lbName.ItemHeight;
                    this.Height   += lbName.ItemHeight;
                }
            }
            lbCode.Size = new Size(90, this.ClientSize.Height - 10 - lbCode.Top);
            lbName.Size = new Size(this.ClientSize.Width - 10 - lbName.Left, this.ClientSize.Height - 10 - lbName.Top);

            lbName.Focus();
            lbName.SelectedIndexChanged += new EventHandler(lbName_SelectedIndexChanged);
            lbName.KeyDown += new KeyEventHandler(lbName_KeyDown);
            lbCode.KeyDown += new KeyEventHandler(lbName_KeyDown);
            lbCode.SelectedIndexChanged += new EventHandler(lbCode_SelectedIndexChanged);

            if (lbName.Items.Count >= 1)
            {
                lbName.SelectedIndex = 0;
            }

            this.Text = "Select A Supplier";
        }
예제 #10
0
        public frmInvoiceCosts(ref StockEngine se)
        {
            sEngine   = se;
            this.Size = new Size(1024, 768);
            this.SurroundListBoxes = true;

            lbBarcode                       = new CListBox();
            lbBarcode.Location              = new Point(10, 31);
            lbBarcode.Size                  = new Size(200, this.ClientSize.Height - 10 - lbBarcode.Top);
            lbBarcode.BorderStyle           = BorderStyle.None;
            lbBarcode.KeyDown              += new KeyEventHandler(lbKeyDown);
            lbBarcode.SelectedIndexChanged += new EventHandler(lbSelChanged);
            this.Controls.Add(lbBarcode);
            AddMessage("BARCODE", "Barcode", new Point(10, 10));

            lbDesc                       = new CListBox();
            lbDesc.Location              = new Point(210, 31);
            lbDesc.Size                  = new Size(300, this.ClientSize.Height - 10 - lbBarcode.Top);
            lbDesc.BorderStyle           = BorderStyle.None;
            lbDesc.KeyDown              += new KeyEventHandler(lbKeyDown);
            lbDesc.SelectedIndexChanged += new EventHandler(lbSelChanged);
            this.Controls.Add(lbDesc);
            AddMessage("DESC", "Description", new Point(210, 10));

            lbQtyRecd                       = new CListBox();
            lbQtyRecd.Location              = new Point(510, 31);
            lbQtyRecd.Size                  = new Size(100, this.ClientSize.Height - 10 - lbBarcode.Top);
            lbQtyRecd.BorderStyle           = BorderStyle.None;
            lbQtyRecd.KeyDown              += new KeyEventHandler(lbKeyDown);
            lbQtyRecd.RightToLeft           = RightToLeft.Yes;
            lbQtyRecd.SelectedIndexChanged += new EventHandler(lbSelChanged);
            this.Controls.Add(lbQtyRecd);
            AddMessage("RECD", "Qty Received", new Point(510, 10));

            lbCost                       = new CListBox();
            lbCost.Location              = new Point(610, 31);
            lbCost.Size                  = new Size(100, this.ClientSize.Height - 10 - lbBarcode.Top);
            lbCost.BorderStyle           = BorderStyle.None;
            lbCost.KeyDown              += new KeyEventHandler(lbKeyDown);
            lbCost.RightToLeft           = RightToLeft.Yes;
            lbCost.SelectedIndexChanged += new EventHandler(lbSelChanged);
            this.Controls.Add(lbCost);
            AddMessage("COST", "Cost", new Point(610, 10));

            this.VisibleChanged += new EventHandler(frmInvoiceCosts_VisibleChanged);
            this.FormClosing    += new FormClosingEventHandler(frmInvoiceCosts_FormClosing);
            this.AllowScaling    = false;
            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedToolWindow;
            this.Text            = "Enter Invoice Costs";
            this.Width           = lbCost.Left + lbCost.Width + 10 + (this.Width - this.ClientSize.Width);
            // Get the settlement discount
            EnterSettlementDiscount();
        }
예제 #11
0
        public frmSuppliersForItem(ref StockEngine se, string Barcode)
        {
            sEngine                = se;
            this.AllowScaling      = false;
            this.Size              = new Size(400, 240);
            this.FormBorderStyle   = FormBorderStyle.FixedToolWindow;
            this.Text              = "Suppliers for " + sEngine.GetMainStockInfo(Barcode)[1];
            this.SurroundListBoxes = true;

            int nOfResults = 0;

            string[,] sSuppliers = sEngine.GetListOfSuppliersForItem(Barcode, ref nOfResults);

            AddMessage("NAME", "Supplier Name", new Point(10, 10));
            lbSupName                       = new CListBox();
            lbSupName.Location              = new Point(10, 35);
            lbSupName.Size                  = new Size(200, this.ClientSize.Height - lbSupName.Top - 10);
            lbSupName.SelectedIndexChanged += new EventHandler(lbSelectedChanged);
            lbSupName.BorderStyle           = BorderStyle.None;
            lbSupName.KeyDown              += new KeyEventHandler(lbKeyDown);
            this.Controls.Add(lbSupName);

            AddMessage("COST", "Last Cost", new Point(210, 10));
            lbSupCost                       = new CListBox();
            lbSupCost.Location              = new Point(210, 35);
            lbSupCost.Size                  = new Size(75, this.ClientSize.Height - lbSupName.Top - 10);
            lbSupCost.SelectedIndexChanged += new EventHandler(lbSelectedChanged);
            lbSupCost.RightToLeft           = RightToLeft.Yes;
            lbSupCost.BorderStyle           = BorderStyle.None;
            lbSupCost.KeyDown              += new KeyEventHandler(lbKeyDown);
            this.Controls.Add(lbSupCost);

            AddMessage("CODE", "Supplier Code", new Point(285, 10));
            lbSupCode                       = new CListBox();
            lbSupCode.Location              = new Point(285, 35);
            lbSupCode.Size                  = new Size(this.ClientSize.Width - lbSupCode.Left - 10, this.ClientSize.Height - lbSupName.Top - 10);
            lbSupCode.SelectedIndexChanged += new EventHandler(lbSelectedChanged);
            lbSupCode.BorderStyle           = BorderStyle.None;
            lbSupCode.KeyDown              += new KeyEventHandler(lbKeyDown);
            this.Controls.Add(lbSupCode);

            for (int i = 0; i < nOfResults; i++)
            {
                lbSupName.Items.Add(sEngine.GetSupplierDetails(sSuppliers[i, 1])[1]);
                lbSupCost.Items.Add(FormatMoneyForDisplay(sSuppliers[i, 3]));
                lbSupCode.Items.Add(sSuppliers[i, 2]);
            }

            if (nOfResults > 0)
            {
                lbSupName.SelectedIndex = 0;
            }
        }
예제 #12
0
    public bool LoadTemplateList(BaseMaster BaseMstr,
                                 ListBox lstTemplates)
    {
        CListBox lst = new CListBox();

        DataSet dsTemplates = GetTemplateDS(BaseMstr);

        lst.RenderDataSet(BaseMstr,
                          dsTemplates,
                          lstTemplates,
                          "DESCRIPTION",
                          "TEMPLATE_ID");

        return(true);
    }
예제 #13
0
    //load a dropdown list of military services
    public void LoadMAJCOMList(BaseMaster BaseMstr,
                               ListBox lst)
    {
        //get the data to load
        DataSet ds = m_Military.GetMAJCOMDS(BaseMstr);

        //load the combo
        CListBox l = new CListBox();

        l.RenderDataSet(BaseMstr,
                        ds,
                        lst,
                        "MAJCOM_TITLE",
                        "MAJCOM_ID");
    }
예제 #14
0
    //load a dropdown list of military services
    public void LoadMAJCOMBaseList(BaseMaster BaseMstr,
                                   ListBox lst,
                                   long lMAJCOMID)
    {
        //get the data to load
        DataSet ds = m_Military.GetMAJCOMBaseDS(BaseMstr, lMAJCOMID);

        //load the combo
        CListBox cl = new CListBox();

        cl.RenderDataSet(BaseMstr,
                         ds,
                         lst,
                         "BASE",
                         "DIMS_ID");
    }
 public frmSalesReportType()
 {
     this.AllowScaling    = false;
     this.FormBorderStyle = FormBorderStyle.FixedToolWindow;
     this.Size            = new Size(240, 90);
     this.Text            = "Show on the report...";
     lbOptions            = new CListBox();
     lbOptions.Items.Add("All Sold Stock & Category Totals");
     lbOptions.Items.Add("Category Totals Only");
     this.Controls.Add(lbOptions);
     lbOptions.Location      = new Point(10, 10);
     lbOptions.Size          = new Size(this.ClientSize.Width - 10 - lbOptions.Left, this.ClientSize.Height - 20);
     lbOptions.BorderStyle   = BorderStyle.FixedSingle;
     lbOptions.KeyDown      += new KeyEventHandler(lbOptions_KeyDown);
     lbOptions.SelectedIndex = 0;
 }
예제 #16
0
        public frmListOfVATRates(ref StockEngine se)
        {
            sEngine = se;
            AddMessage("CODE", "VAT Name", new Point(10, 10));
            AddMessage("NAME", "VAT Rate", new Point(160, 10));
            this.AllowScaling      = false;
            this.Size              = new Size(260, 100);
            this.FormBorderStyle   = FormBorderStyle.FixedToolWindow;
            this.Text              = "Select A VAT Rate";
            this.SurroundListBoxes = true;

            lbCode             = new CListBox();
            lbCode.Location    = new Point(10, BelowLastControl);
            lbCode.Size        = new Size(150, lbCode.ItemHeight);
            lbCode.BorderStyle = BorderStyle.None;
            this.Controls.Add(lbCode);

            lbName             = new CListBox();
            lbName.Location    = new Point(160, lbCode.Top);
            lbName.BorderStyle = BorderStyle.None;
            lbName.Size        = new Size(this.ClientSize.Width - 10 - 150 - 10, lbName.ItemHeight);
            lbName.RightToLeft = System.Windows.Forms.RightToLeft.Yes;
            this.Controls.Add(lbName);

            string[,] sVATCodes = sEngine.VATRates;
            sListOfVATCodes     = new string[sEngine.NumberOfVATRates];
            for (int i = 0; i < sEngine.NumberOfVATRates; i++)
            {
                lbCode.Items.Add(sVATCodes[i, 1]);
                lbName.Items.Add(FormatMoneyForDisplay(Convert.ToDecimal(sVATCodes[i, 2])) + "%");
                lbCode.Height     += lbCode.ItemHeight;
                lbName.Height     += lbName.ItemHeight;
                this.Height       += lbName.ItemHeight;
                sListOfVATCodes[i] = sVATCodes[i, 0];
            }

            lbName.Focus();
            lbName.SelectedIndexChanged += new EventHandler(lbName_SelectedIndexChanged);
            lbName.KeyDown += new KeyEventHandler(lbName_KeyDown);
            lbCode.KeyDown += new KeyEventHandler(lbName_KeyDown);
            lbCode.SelectedIndexChanged += new EventHandler(lbCode_SelectedIndexChanged);

            if (lbName.Items.Count >= 1)
            {
                lbName.SelectedIndex = 0;
            }
        }
예제 #17
0
        public frmListOfCategoryGroups(ref StockEngine se)
        {
            sEngine              = se;
            this.AllowScaling    = false;
            this.Text            = "Select A Category Group";
            this.FormBorderStyle = FormBorderStyle.FixedToolWindow;
            this.Size            = new Size(220, 450);

            lbListOfCats             = new CListBox();
            lbListOfCats.Location    = new Point(10, 10);
            lbListOfCats.Size        = new Size(this.ClientSize.Width - 20, this.ClientSize.Height - 20);
            lbListOfCats.BorderStyle = BorderStyle.FixedSingle;
            this.Controls.Add(lbListOfCats);
            lbListOfCats.Items.AddRange(sEngine.GetListOfCategoryGroupNames());
            lbListOfCats.KeyDown      += new KeyEventHandler(lbListOfCats_KeyDown);
            lbListOfCats.SelectedIndex = 0;
        }
예제 #18
0
    //load a dropdown list of military services
    public void LoadDMISAllSquadronsList(BaseMaster BaseMstr,
                                         ListBox lst,
                                         string strDMISID)
    {
        //get the data to load by DMISID
        DataSet ds = m_Military.GetDMISAllSquadronsDS(BaseMstr,
                                                      strDMISID);

        //load the combo
        CListBox l = new CListBox();

        l.RenderDataSet(BaseMstr,
                        ds,
                        lst,
                        "SQUADRON",
                        "SQUADRON_ID");
    }
예제 #19
0
        public frmListOfTills(ref StockEngine se, string sShopCode)
        {
            sEngine = se;
            AddMessage("CODE", "Till Code", new Point(10, 10));
            AddMessage("NAME", "Till Name", new Point(100, 10));
            this.AllowScaling    = false;
            this.Size            = new Size(280, 100);
            this.FormBorderStyle = FormBorderStyle.FixedToolWindow;
            this.Text            = "Select A Till";

            lbCode             = new CListBox();
            lbCode.Location    = new Point(10, BelowLastControl);
            lbCode.Size        = new Size(90, lbCode.ItemHeight);
            lbCode.BorderStyle = BorderStyle.None;
            this.Controls.Add(lbCode);

            lbName             = new CListBox();
            lbName.Location    = new Point(100, lbCode.Top);
            lbName.BorderStyle = BorderStyle.None;
            lbName.Size        = new Size(150, lbName.ItemHeight);
            this.Controls.Add(lbName);

            string[] sTillCodes = sEngine.GetListOfTillCodes(sShopCode);
            for (int i = 0; i < sEngine.NumberOfTills(sShopCode); i++)
            {
                string[] sTillData = sEngine.GetTillData(sTillCodes[i]);
                lbCode.Items.Add(sTillData[0]);
                lbName.Items.Add(sTillData[1]);
                lbCode.Height += lbCode.ItemHeight;
                lbName.Height += lbName.ItemHeight;
                this.Height   += lbName.ItemHeight;
            }

            lbName.Focus();
            lbName.SelectedIndexChanged += new EventHandler(lbName_SelectedIndexChanged);
            lbName.KeyDown += new KeyEventHandler(lbName_KeyDown);
            lbCode.KeyDown += new KeyEventHandler(lbName_KeyDown);
            lbCode.SelectedIndexChanged += new EventHandler(lbCode_SelectedIndexChanged);

            if (lbName.Items.Count >= 1)
            {
                lbName.SelectedIndex = 0;
            }

            this.Text = "Select A Till";
        }
 public frmStockReportOrder()
 {
     this.AllowScaling    = false;
     this.FormBorderStyle = FormBorderStyle.FixedToolWindow;
     this.Size            = new Size(220, 105);
     this.Text            = "Report Sort Order";
     lbOptions            = new CListBox();
     lbOptions.Items.Add("Barcode Alphabetically");
     lbOptions.Items.Add("Description Alphabetically");
     lbOptions.Items.Add("Quantity In stock Descending");
     this.Controls.Add(lbOptions);
     lbOptions.Location      = new Point(10, 10);
     lbOptions.Size          = new Size(this.ClientSize.Width - this.lbOptions.Left - 10, this.ClientSize.Height - this.lbOptions.Top - 10);
     lbOptions.BorderStyle   = BorderStyle.None;
     lbOptions.KeyDown      += new KeyEventHandler(lbOptions_KeyDown);
     lbOptions.SelectedIndex = 1;
     this.SurroundListBoxes  = true;
 }
예제 #21
0
        public frmListOfSales(ref StockEngine sEngine, string sBarcode)
        {
            this.sEngine           = sEngine;
            this.AllowScaling      = false;
            this.sBarcode          = sBarcode;
            this.FormBorderStyle   = FormBorderStyle.FixedToolWindow;
            this.Size              = new System.Drawing.Size(275, 420);
            this.SurroundListBoxes = true;

            AddMessage("INST", "Sales Date  -  Transaction Number", new System.Drawing.Point(10, 10));

            lbSales             = new CListBox();
            lbSales.Location    = new System.Drawing.Point(10, BelowLastControl);
            lbSales.Size        = new System.Drawing.Size(this.ClientSize.Width - 20, 300);
            lbSales.BorderStyle = BorderStyle.None;
            this.Controls.Add(lbSales);

            AddMessage("NOTE", "Only sales before this week are shown", new System.Drawing.Point(10, 340));
            AddMessage("NOTE2", "Press Enter to view the transaction", new System.Drawing.Point(10, 360));

            sTranNo    = new string[0];
            sSalesDate = sEngine.GetWeeksOfItemSold(sBarcode, ref sTranNo);

            frmProgressBar fp = new frmProgressBar("Getting Sales Dates");

            fp.pb.Maximum = sSalesDate.Length;
            fp.Show();
            for (int i = 0; i < sSalesDate.Length; i++)
            {
                fp.pb.Value = i;
                string sDay = sEngine.WorkOutDateOfSale(sTranNo[i], sSalesDate[i]);
                BackOffice.Database_Engine.Table t = new BackOffice.Database_Engine.Table("Archive\\Weekly\\" + sSalesDate[i] + "\\TILL1\\INGNG\\REPDATA" + sDay + ".DBF");
                string sDate = t.GetRecordFrom(0)[1];
                lbSales.Items.Add(sDate + " - " + sTranNo[i]);
            }
            if (lbSales.Items.Count > 0)
            {
                lbSales.SelectedIndex = 0;
            }
            fp.Close();
            lbSales.KeyDown += new KeyEventHandler(lbSales_KeyDown);
        }
예제 #22
0
        public frmListOfOrders(ref StockEngine se)
        {
            sEngine = se;
            this.FormBorderStyle   = FormBorderStyle.FixedToolWindow;
            this.AllowScaling      = false;
            this.SurroundListBoxes = true;
            this.Size = new System.Drawing.Size(500, 520);

            lbOrderNum                       = new CListBox();
            lbOrderNum.Location              = new Point(10, 10);
            lbOrderNum.Size                  = new Size(140, 400);
            lbOrderNum.BorderStyle           = BorderStyle.None;
            lbOrderNum.KeyDown              += new KeyEventHandler(lbOrderNum_KeyDown);
            lbOrderNum.SelectedIndexChanged += new EventHandler(lbOrderNum_SelectedIndexChanged);
            this.Controls.Add(lbOrderNum);

            lbSupplierName                       = new CListBox();
            lbSupplierName.Location              = new Point(150, 10);
            lbSupplierName.Size                  = new Size(240, 400);
            lbSupplierName.BorderStyle           = BorderStyle.None;
            lbSupplierName.KeyDown              += new KeyEventHandler(lbOrderNum_KeyDown);
            lbSupplierName.SelectedIndexChanged += new EventHandler(lbOrderNum_SelectedIndexChanged);
            this.Controls.Add(lbSupplierName);

            lbOrderDate                       = new CListBox();
            lbOrderDate.Location              = new Point(390, 10);
            lbOrderDate.Size                  = new Size(this.ClientSize.Width - 10 - lbOrderDate.Left, 400);
            lbOrderDate.BorderStyle           = BorderStyle.None;
            lbOrderDate.KeyDown              += new KeyEventHandler(lbOrderNum_KeyDown);
            lbOrderDate.SelectedIndexChanged += new EventHandler(lbOrderNum_SelectedIndexChanged);
            this.Controls.Add(lbOrderDate);

            btnAddOrder          = new Button();
            btnAddOrder.Size     = new Size(200, 50);
            btnAddOrder.Location = new Point(10, this.ClientSize.Height - btnAddOrder.Height - 10);
            btnAddOrder.Text     = "Add Empty Order : Press Insert";
            btnAddOrder.Click   += new EventHandler(btnAddOrder_Click);

            LoadOrders();

            this.Text = "Select An Order";
        }
예제 #23
0
    //loads a combo with auxilary bases
    public bool LoadAuxSquadronList(BaseMaster BaseMstr,
                                    string strDIMSID,
                                    string strAuxDMISID,
                                    ListBox lst)
    {
        DataSet ds = m_Military.GetAuxSquadronDS(BaseMstr,
                                                 strDIMSID,
                                                 strAuxDMISID);

        //load the combo
        CListBox lb = new CListBox();

        lb.RenderDataSet(BaseMstr,
                         ds,
                         lst,
                         "SQUADRON",
                         "SQUADRON_ID");


        return(true);
    }
예제 #24
0
 public frmSalesReportOrder()
 {
     this.AllowScaling    = false;
     this.FormBorderStyle = FormBorderStyle.FixedToolWindow;
     this.Size            = new Size(220, 180);
     this.Text            = "Sort Report By...";
     lbOptions            = new CListBox();
     lbOptions.Items.Add("Description Alphabetically");
     lbOptions.Items.Add("Quantity Sold Descending");
     lbOptions.Items.Add("Barcode Alphabetically");
     lbOptions.Items.Add("Gross Sales Descending");
     lbOptions.Items.Add("Net Sales Descending");
     lbOptions.Items.Add("Profit Descending");
     lbOptions.Items.Add("Profit Percent Descending");
     this.Controls.Add(lbOptions);
     lbOptions.Location      = new Point(10, 10);
     lbOptions.Size          = new Size(this.ClientSize.Width - 20, this.ClientSize.Height - 20);
     lbOptions.BorderStyle   = BorderStyle.FixedSingle;
     lbOptions.KeyDown      += new KeyEventHandler(lbOptions_KeyDown);
     lbOptions.SelectedIndex = 0;
 }
        public frmListOfAccounts(ref StockEngine se)
        {
            this.AllowScaling    = false;
            this.FormBorderStyle = FormBorderStyle.FixedToolWindow;
            sEngine = se;

            AddMessage("CODE", "Code", new Point(10, 10));
            AddMessage("NAME", "Name", new Point(100, 10));

            lbAccCode                       = new CListBox();
            lbAccCode.Location              = new Point(10, BelowLastControl);
            lbAccCode.Size                  = new Size(90, 400);
            lbAccCode.BorderStyle           = BorderStyle.None;
            lbAccCode.SelectedIndexChanged += new EventHandler(lbSelectedChanged);
            lbAccCode.KeyDown              += new KeyEventHandler(lbKeyDown);
            this.Controls.Add(lbAccCode);

            lbAccName                       = new CListBox();
            lbAccName.Location              = new Point(100, lbAccCode.Top);
            lbAccName.Size                  = new Size(300, 400);
            lbAccName.BorderStyle           = BorderStyle.None;
            lbAccName.SelectedIndexChanged += new EventHandler(lbSelectedChanged);
            lbAccName.KeyDown              += new KeyEventHandler(lbKeyDown);
            this.Controls.Add(lbAccName);

            this.Size = new Size(450, 500);

            string[] sAccounts = sEngine.GetListOfAccountCodes();
            for (int i = 0; i < sAccounts.Length; i++)
            {
                lbAccCode.Items.Add(sAccounts[i]);
                lbAccName.Items.Add(sEngine.GetAccountName(sAccounts[i]));
            }
            if (lbAccCode.Items.Count > 0)
            {
                lbAccCode.SelectedIndex = 0;
            }

            this.Text = "Select An Account";
        }
        public frmCategorySelect(ref StockEngine se)
        {
            sEngine = se;

            this.FormBorderStyle = FormBorderStyle.FixedToolWindow;
            this.Size            = new Size(250, 510);
            this.AllowScaling    = false;
            this.Text            = "Select A Category";

            AddMessage("INST1", "Insert Key to edit categories", new Point(10, 10));
            AddMessage("INST2", "F6 to select the last category", new Point(10, 30));
            AddMessage("INST3", "Space to select the category (any level)", new Point(10, 50));
            lbCategories               = new CListBox();
            lbCategories.Location      = new Point(10, 70);
            lbCategories.ShowScrollbar = true;
            lbCategories.Size          = new Size(this.ClientSize.Width - 20, this.ClientSize.Height - 70);
            lbCategories.BorderStyle   = BorderStyle.FixedSingle;
            lbCategories.KeyDown      += new KeyEventHandler(lbCategories_KeyDown);
            this.Controls.Add(lbCategories);

            ShowCategories("");
        }
예제 #27
0
 void SetupForm()
 {
     AddMessage("SHOP", "Select the shop : ", new System.Drawing.Point(10, 10));
     this.AllowScaling    = false;
     this.FormBorderStyle = FormBorderStyle.SizableToolWindow;
     this.Size            = new System.Drawing.Size(340, 75);
     lbShopName           = new CListBox();
     lbShopName.Location  = new System.Drawing.Point(10, 40);
     lbShopName.Size      = new System.Drawing.Size(300, 0);
     this.Controls.Add(lbShopName);
     sListOfCodes = sEngine.GetListOfShopCodes();
     for (int i = 0; i < sEngine.NumberOfShops; i++)
     {
         lbShopName.Items.Add(sEngine.GetShopNameFromCode(sListOfCodes[i]));
     }
     lbShopName.Height        = lbShopName.ItemHeight * (sEngine.NumberOfShops + 1);
     this.Height             += (lbShopName.ItemHeight * (sEngine.NumberOfShops + 1));
     lbShopName.SelectedIndex = 0;
     lbShopName.KeyDown      += new KeyEventHandler(lbShopName_KeyDown);
     this.Shown += new EventHandler(frmListOfShops_Shown);
     this.Text   = "Select A Shop";
 }
예제 #28
0
        public frmAddEditStaff(ref StockEngine se)
        {
            sEngine = se;

            this.AllowScaling = false;
            this.Size         = new Size(300, 360);

            frmListOfShops flos = new frmListOfShops(ref sEngine);

            flos.ShowDialog();
            if (flos.SelectedShopCode != "$NONE")
            {
                sShopCode = flos.SelectedShopCode;
            }

            AddMessage("NUM", "ID Number", new Point(10, 10));
            lbNumbers                       = new CListBox();
            lbNumbers.Location              = new Point(10, 40);
            lbNumbers.Size                  = new Size(75, this.ClientSize.Height - 10 - lbNumbers.Top);
            lbNumbers.BorderStyle           = BorderStyle.None;
            lbNumbers.KeyDown              += new KeyEventHandler(lbKeyDown);
            lbNumbers.SelectedIndexChanged += new EventHandler(lbSelectedChanged);
            this.Controls.Add(lbNumbers);

            AddMessage("NAME", "Staff Name", new Point(85, 10));
            lbStaff                       = new CListBox();
            lbStaff.Location              = new Point(85, 40);
            lbStaff.Size                  = new Size(200, this.ClientSize.Height - 10 - lbNumbers.Top);
            lbStaff.BorderStyle           = BorderStyle.None;
            lbStaff.KeyDown              += new KeyEventHandler(lbKeyDown);
            lbStaff.SelectedIndexChanged += new EventHandler(lbSelectedChanged);
            this.Controls.Add(lbStaff);

            this.VisibleChanged += new EventHandler(frmAddEditStaff_VisibleChanged);
            this.FormBorderStyle = FormBorderStyle.FixedToolWindow;
            this.Text            = "Edit Staff";
        }
예제 #29
0
        public frmOrderSuggestions(ref StockEngine se, string sShpCode, string sSupCode)
        {
            this.AllowScaling = false;
            sEngine           = se;
            sShopCode         = sShpCode;
            AddMessage("INST", "Staff have suggested that the following items be included in this order :", new Point(10, 10));
            AddMessage("INST2", "(Press enter on each item to include it in the order. Y = include, N = delete, '' = ignore)", new Point(10, BelowLastControl));

            AddMessage("BARCODE", "Barcode", new Point(10, BelowLastControl));
            lbBarcode                       = new CListBox();
            lbBarcode.Location              = new Point(10, BelowLastControl);
            lbBarcode.Size                  = new Size(150, 300);
            lbBarcode.SelectedIndexChanged += new EventHandler(lbSelectedChanged);
            lbBarcode.KeyDown              += new KeyEventHandler(lbKeyDown);
            lbBarcode.BorderStyle           = BorderStyle.None;
            this.Controls.Add(lbBarcode);

            AddMessage("DESC", "Description", new Point(160, MessageLabel("BARCODE").Top));
            lbDesc                       = new CListBox();
            lbDesc.Location              = new Point(160, lbBarcode.Top);
            lbDesc.Size                  = new Size(200, 300);
            lbDesc.BorderStyle           = BorderStyle.None;
            lbDesc.SelectedIndexChanged += new EventHandler(lbSelectedChanged);
            lbDesc.KeyDown              += new KeyEventHandler(lbKeyDown);
            this.Controls.Add(lbDesc);

            AddMessage("SUGDATE", "Date Suggested", new Point(360, MessageLabel("BARCODE").Top));
            lbSugDate                       = new CListBox();
            lbSugDate.Location              = new Point(360, lbBarcode.Top);
            lbSugDate.Size                  = new Size(150, 300);
            lbSugDate.BorderStyle           = BorderStyle.None;
            lbSugDate.SelectedIndexChanged += new EventHandler(lbSelectedChanged);
            lbSugDate.KeyDown              += new KeyEventHandler(lbKeyDown);
            this.Controls.Add(lbSugDate);

            AddMessage("INC", "Including", new Point(470, MessageLabel("BARCODE").Top));
            lbIncluding                       = new CListBox();
            lbIncluding.Location              = new Point(510, lbBarcode.Top);
            lbIncluding.Size                  = new Size(30, 300);
            lbIncluding.BorderStyle           = BorderStyle.None;
            lbIncluding.SelectedIndexChanged += new EventHandler(lbSelectedChanged);
            lbIncluding.KeyDown              += new KeyEventHandler(lbKeyDown);
            this.Controls.Add(lbIncluding);

            int nOfResults = 0;

            string[,] sSugs = sEngine.GetSuggestedItemsForOrder(sSupCode, sShopCode, ref nOfResults);
            for (int i = 0; i < nOfResults; i++)
            {
                lbBarcode.Items.Add(sSugs[i, 0]);
                lbDesc.Items.Add(sEngine.GetMainStockInfo(sSugs[i, 0])[1]);
                string sDate = sSugs[i, 1][0].ToString() + sSugs[i, 1][1].ToString() + "/" + sSugs[i, 1][2].ToString() + sSugs[i, 1][3].ToString() + "/" + sSugs[i, 1][4].ToString() + sSugs[i, 1][5].ToString();
                lbSugDate.Items.Add(sDate);
                lbIncluding.Items.Add("");
            }
            lbBarcode.SelectedIndex = 0;

            this.Size            = new Size(550, 400);
            this.FormBorderStyle = FormBorderStyle.FixedToolWindow;
            this.VisibleChanged += new EventHandler(frmOrderSuggestions_VisibleChanged);

            this.Text = "Order Suggestions";
        }
예제 #30
0
        public frmOrdersWithItemIn(ref StockEngine se, string sBarcode)
        {
            sEngine                = se;
            this.AllowScaling      = false;
            this.Size              = new Size(500, 200);
            this.FormBorderStyle   = FormBorderStyle.FixedToolWindow;
            this.KeyDown          += new KeyEventHandler(frmOrdersWithItemIn_KeyDown);
            this.SurroundListBoxes = true;

            lbOrderNum                       = new CListBox();
            lbOrderNum.Location              = new Point(10, 40);
            lbOrderNum.Size                  = new Size(75, this.ClientSize.Height - 10 - lbOrderNum.Top);
            lbOrderNum.BorderStyle           = BorderStyle.None;
            lbOrderNum.KeyDown              += new KeyEventHandler(lbOrderNum_KeyDown);
            lbOrderNum.SelectedIndexChanged += new EventHandler(lbOrderNum_SelectedIndexChanged);
            this.Controls.Add(lbOrderNum);
            AddMessage("ORDNUM", "Order Num", new Point(10, 10));

            lbSupCode                       = new CListBox();
            lbSupCode.Location              = new Point(lbOrderNum.Left + lbOrderNum.Width, 40);
            lbSupCode.Size                  = new Size(100, this.ClientSize.Height - 10 - lbOrderNum.Top);
            lbSupCode.BorderStyle           = BorderStyle.None;
            lbSupCode.KeyDown              += new KeyEventHandler(lbOrderNum_KeyDown);
            lbSupCode.SelectedIndexChanged += new EventHandler(lbOrderNum_SelectedIndexChanged);
            this.Controls.Add(lbSupCode);
            AddMessage("SUPCODE", "Sup Code", new Point(lbSupCode.Left, 10));

            lbSupName                       = new CListBox();
            lbSupName.Location              = new Point(lbSupCode.Left + lbSupCode.Width, 40);
            lbSupName.Size                  = new Size(200, this.ClientSize.Height - 10 - lbOrderNum.Top);
            lbSupName.BorderStyle           = BorderStyle.None;
            lbSupName.KeyDown              += new KeyEventHandler(lbOrderNum_KeyDown);
            lbSupName.SelectedIndexChanged += new EventHandler(lbOrderNum_SelectedIndexChanged);
            this.Controls.Add(lbSupName);
            AddMessage("SUPNAME", "Supplier Name", new Point(lbSupName.Left, 10));

            lbQtyOnOrder                       = new CListBox();
            lbQtyOnOrder.Location              = new Point(lbSupName.Left + lbSupName.Width, 40);
            lbQtyOnOrder.Size                  = new Size(this.ClientSize.Width - 10 - lbQtyOnOrder.Left, this.ClientSize.Height - 10 - lbOrderNum.Top);
            lbQtyOnOrder.BorderStyle           = BorderStyle.None;
            lbQtyOnOrder.KeyDown              += new KeyEventHandler(lbOrderNum_KeyDown);
            lbQtyOnOrder.SelectedIndexChanged += new EventHandler(lbOrderNum_SelectedIndexChanged);
            this.Controls.Add(lbQtyOnOrder);
            AddMessage("QTY", "Outstanding", new Point(lbQtyOnOrder.Left, 10));

            string[] sOrderNums  = new string[0];
            string[] sSupCodes   = new string[0];
            string[] sQuantities = new string[0];
            sEngine.GetOrdersWithItemOutstandingIn(sBarcode, ref sOrderNums, ref sSupCodes, ref sQuantities);

            lbOrderNum.Items.AddRange(sOrderNums);
            lbSupCode.Items.AddRange(sSupCodes);
            lbQtyOnOrder.Items.AddRange(sQuantities);
            for (int i = 0; i < sSupCodes.Length; i++)
            {
                lbSupName.Items.Add(sEngine.GetSupplierDetails(sSupCodes[i])[1]);
            }
            if (lbSupName.Items.Count > 0)
            {
                lbSupName.SelectedIndex = 0;
            }

            this.Text = "Orders With Item Outstanding";
        }