Esempio n. 1
0
        private void OnFormLoad(object sender, System.EventArgs e)
        {
            //Form load event handler
            this.Cursor = Cursors.WaitCursor;
            try {
                //Show early
                this.Visible = true;
                Application.DoEvents();

                //Load agent summarymEntTerminal
                this.grdAgentSummary.Text = "Agent Summary for " + this.mTerminalName;
                this.grdAgentSummary.DisplayLayout.Bands[0].Override.RowFilterMode = RowFilterMode.AllRowsInBand;
                this.grdAgentSummary.DisplayLayout.Bands[0].Columns["AgentNumber"].SortIndicator = SortIndicator.Ascending;
                this.mTLs.Merge(FreightGateway.GetAgentSummary(this.mTerminalID));
                if (this.grdAgentSummary.Rows.Count > 0)
                {
                    this.grdAgentSummary.Rows[0].Selected = this.grdAgentSummary.Rows[0].Activate();
                }
                this.cmdPrint.Enabled = (this.grdAgentSummary.Rows.Count > 0);
            }
            catch (Exception ex) { throw ex; }
            finally { this.Cursor = Cursors.Default; }
        }