From 8af1be04a3be79a9c20bbdaf94eb3628e27d26f0 Mon Sep 17 00:00:00 2001 From: sam Date: Thu, 6 Jan 2011 09:25:38 +0000 Subject: [PATCH] Progress Bar on Splash Screen and supporting code --- cs/bsdx0200GUISourceCode/CGDocumentManager.cs | 136 ++++++++++++------ .../ClinicalScheduling.csproj.user | 2 +- .../ClinicalScheduling.suo | Bin 216064 -> 219136 bytes cs/bsdx0200GUISourceCode/DSplash.cs | 39 ++++- 4 files changed, 130 insertions(+), 47 deletions(-) diff --git a/cs/bsdx0200GUISourceCode/CGDocumentManager.cs b/cs/bsdx0200GUISourceCode/CGDocumentManager.cs index b9b65c5..4a1dd7f 100644 --- a/cs/bsdx0200GUISourceCode/CGDocumentManager.cs +++ b/cs/bsdx0200GUISourceCode/CGDocumentManager.cs @@ -187,7 +187,9 @@ namespace IndianHealthService.ClinicalScheduling opset.Parse(args); - _current.InitializeApp(); + bool isEverythingOkay = _current.InitializeApp(); + + if (!isEverythingOkay) return; //Create the first empty document CGDocument doc = new CGDocument(); @@ -250,9 +252,9 @@ namespace IndianHealthService.ClinicalScheduling /// /// See InitializeApp(bool) below /// - private void InitializeApp() + private bool InitializeApp() { - InitializeApp(false); + return InitializeApp(false); } /// @@ -263,7 +265,7 @@ namespace IndianHealthService.ClinicalScheduling /// /// Is the User logging in again from a currently running instance? /// If so, display a dialog to collect access and verify codes. - private void InitializeApp(bool bReLogin) + private bool InitializeApp(bool bReLogin) { //Set M connection info m_ConnectInfo = new BMXNetConnectInfo(m_Encoding); // Encoding is "" unless passed in command line @@ -277,33 +279,33 @@ namespace IndianHealthService.ClinicalScheduling //Disable polling (But does this really work???? I don't see how it gets disabled) m_ConnectInfo.EventPollingEnabled = false; - //Show a splash screen while initializing + //Show a splash screen while initializing; define delegates to remote thread DSplash m_ds = new DSplash(); DSplash.dSetStatus setStatusDelegate = new DSplash.dSetStatus(m_ds.SetStatus); DSplash.dAny closeSplashDelegate = new DSplash.dAny(m_ds.RemoteClose); - DSplash.dAny hideSplashDelegate = new DSplash.dAny(m_ds.RemoteHide); + DSplash.dProgressBarSet setMaxProgressDelegate = new DSplash.dProgressBarSet(m_ds.RemoteProgressBarMaxSet); + DSplash.dProgressBarSet setProgressDelegate = new DSplash.dProgressBarSet(m_ds.RemoteProgressBarValueSet); + //Start new thread for the Splash screen. Thread threadSplash = new Thread(new ParameterizedThreadStart(StartSplash)); - threadSplash.IsBackground = true; //expendable -- exit even if still running. - threadSplash.Start(m_ds); + threadSplash.IsBackground = true; //expendable thread -- exit even if still running. + threadSplash.Name = "Splash Thread"; + threadSplash.Start(m_ds); // pass form as parameter. + //There are 20 steps to load the application. That's max for the progress bar. + setMaxProgressDelegate(20); + + // smh--not used: System.Configuration.ConfigurationManager.GetSection("appSettings"); - //m_ds.SetStatus("Loading Configuration Settings..."); - //m_ds.Refresh(); - //this.Activate(); - // smh--not used System.Configuration.ConfigurationManager.GetSection("appSettings"); setStatusDelegate("Connecting to VISTA"); - //m_ds.Refresh(); + bool bRetry = true; //Try to connect using supplied values for Server and Port //Why am I doing this? The library BMX net uses prompts for access and verify code //whether you can connect or not. Not good. So I test first whether //we can connect at all by doing a simple connection and disconnect. - //TODO: Make this more robust by sending a TCPConnect message and seeing if you get a response. - - //m_ds.Refresh(); - + //TODO: Make this more robust by sending a TCPConnect message and seeing if you get a response if (m_Server != "" && m_Port != 0) { System.Net.Sockets.TcpClient tcpClient = new System.Net.Sockets.TcpClient(); @@ -312,13 +314,16 @@ namespace IndianHealthService.ClinicalScheduling tcpClient.Connect(m_Server, m_Port); // open it tcpClient.Close(); // then close it } - catch (System.Net.Sockets.SocketException ex) + catch (System.Net.Sockets.SocketException) { - throw ex; + MessageBox.Show("Cannot connect to VistA. Network Error"); + return false; } } - do + + // Do block is Log-in logic + do { // login crap try @@ -346,11 +351,10 @@ namespace IndianHealthService.ClinicalScheduling } catch (System.Net.Sockets.SocketException) { - MessageBox.Show("Cannot connect to VistA. "); + MessageBox.Show("Cannot connect to VistA. Network Error"); } - catch (Exception ex) + catch (BMXNetException ex) { - //m_ds.Close(); if (MessageBox.Show("Unable to connect to VistA. " + ex.Message, "Clinical Scheduling", MessageBoxButtons.RetryCancel) == DialogResult.Retry) { bRetry = true; @@ -360,7 +364,7 @@ namespace IndianHealthService.ClinicalScheduling { closeSplashDelegate(); bRetry = false; - throw ex; + return false; //tell main that it's a no go. } } }while (bRetry == true); @@ -369,7 +373,8 @@ namespace IndianHealthService.ClinicalScheduling _current.m_dsGlobal = new DataSet("GlobalDataSet"); //Version info - //m_ds.Activate(); + // Table #1 + setProgressDelegate(1); setStatusDelegate("Getting Version Info from Server..."); DataTable ver = _dal.GetVersion("BSDX"); @@ -405,6 +410,8 @@ namespace IndianHealthService.ClinicalScheduling //Change encoding + // Call #2 + setProgressDelegate(2); setStatusDelegate("Setting encoding..."); if (m_Encoding == String.Empty) @@ -413,7 +420,10 @@ namespace IndianHealthService.ClinicalScheduling if (utf8_server_support == "1") m_ConnectInfo.bmxNetLib.Encoder = System.Text.UTF8Encoding.UTF8; } - //Set application context + + //Set application context + // Call #3 + setProgressDelegate(3); setStatusDelegate("Setting Application Context to BSDXRPC..."); m_ConnectInfo.AppContext = "BSDXRPC"; @@ -423,8 +433,10 @@ namespace IndianHealthService.ClinicalScheduling string sCommandText; - setStatusDelegate(statusConst + " Schedule User"); //Schedule User Info + // Table #4 + setProgressDelegate(4); + setStatusDelegate(statusConst + " Schedule User"); DataTable dtUser = _dal.GetUserInfo(m_ConnectInfo.DUZ); dtUser.TableName = "SchedulingUser"; m_dsGlobal.Tables.Add(dtUser); @@ -436,14 +448,18 @@ namespace IndianHealthService.ClinicalScheduling string sUser = oUser.ToString(); m_bSchedManager = (sUser == "YES") ? true : false; - setStatusDelegate(statusConst + " Access Types"); //Get Access Types + // Table #5 + setProgressDelegate(5); + setStatusDelegate(statusConst + " Access Types"); DataTable dtAccessTypes = _dal.GetAccessTypes(); dtAccessTypes.TableName = "AccessTypes"; m_dsGlobal.Tables.Add(dtAccessTypes); + //Get Access Groups + // Table #6 + setProgressDelegate(6); setStatusDelegate(statusConst + " Access Groups"); - //AccessGroups LoadAccessGroupsTable(); //Build Primary Key for AccessGroup table @@ -453,8 +469,10 @@ namespace IndianHealthService.ClinicalScheduling dcKeys[0] = dcKey; dtGroups.PrimaryKey = dcKeys; + //Get Access Group Types (??) + // Table #7 + setProgressDelegate(7); setStatusDelegate(statusConst + " Access Group Types"); - //AccessGroupType LoadAccessGroupTypesTable(); //Build Primary Key for AccessGroupType table @@ -470,12 +488,16 @@ namespace IndianHealthService.ClinicalScheduling m_dsGlobal.Tables["AccessGroupType"].Columns["ACCESS_GROUP_ID"]); //Child m_dsGlobal.Relations.Add(dr); - setStatusDelegate(statusConst + " Resource Groups By User"); //ResourceGroup Table (Resource Groups by User) + // Table #8 + setProgressDelegate(8); + setStatusDelegate(statusConst + " Resource Groups By User"); LoadResourceGroupTable(); - setStatusDelegate(statusConst + " Resources By User"); //Resources by user + // Table #9 + setProgressDelegate(9); + setStatusDelegate(statusConst + " Resources By User"); LoadBSDXResourcesTable(); //Build Primary Key for Resources table @@ -483,8 +505,10 @@ namespace IndianHealthService.ClinicalScheduling dc[0] = m_dsGlobal.Tables["Resources"].Columns["RESOURCEID"]; m_dsGlobal.Tables["Resources"].PrimaryKey = dc; - setStatusDelegate(statusConst + " Group Resources"); //GroupResources table + // Table #10 + setProgressDelegate(10); + setStatusDelegate(statusConst + " Group Resources"); LoadGroupResourcesTable(); //Build Primary Key for ResourceGroup table @@ -499,8 +523,10 @@ namespace IndianHealthService.ClinicalScheduling CGSchedLib.OutputArray(m_dsGlobal.Tables["GroupResources"], "GroupResources"); m_dsGlobal.Relations.Add(dr); - setStatusDelegate(statusConst + " Clinics"); //HospitalLocation table + //Table #11 + setProgressDelegate(11); + setStatusDelegate(statusConst + " Clinics"); //cmd.CommandText = "SELECT BMXIEN 'HOSPITAL_LOCATION_ID', NAME 'HOSPITAL_LOCATION', DEFAULT_PROVIDER, STOP_CODE_NUMBER, INACTIVATE_DATE, REACTIVATE_DATE FROM HOSPITAL_LOCATION"; sCommandText = "BSDX HOSPITAL LOCATION"; ConnectInfo.RPMSDataTable(sCommandText, "HospitalLocation", m_dsGlobal); @@ -518,8 +544,10 @@ namespace IndianHealthService.ClinicalScheduling m_dsGlobal.Tables["Resources"].Columns["HOSPITAL_LOCATION_ID"], false); //Child m_dsGlobal.Relations.Add(dr); - setStatusDelegate(statusConst + " Schedule User"); //Build ScheduleUser table + //Table #12 + setProgressDelegate(12); + setStatusDelegate(statusConst + " Schedule User"); this.LoadScheduleUserTable(); //Build Primary Key for ScheduleUser table @@ -528,8 +556,10 @@ namespace IndianHealthService.ClinicalScheduling dc[0] = dtTemp.Columns["USERID"]; m_dsGlobal.Tables["ScheduleUser"].PrimaryKey = dc; - setStatusDelegate(statusConst + " Resource User"); //Build ResourceUser table + //Table #13 + setProgressDelegate(13); + setStatusDelegate(statusConst + " Resource User"); this.LoadResourceUserTable(); //Build Primary Key for ResourceUser table @@ -544,21 +574,27 @@ namespace IndianHealthService.ClinicalScheduling m_dsGlobal.Tables["ResourceUser"].Columns["RESOURCEID"]); //Child m_dsGlobal.Relations.Add(dr); - setStatusDelegate(statusConst + " Providers"); //Build active provider table + //Table #14 + setProgressDelegate(14); + setStatusDelegate(statusConst + " Providers"); sCommandText = "SELECT BMXIEN, NAME FROM NEW_PERSON WHERE INACTIVE_DATE = '' AND BMXIEN > 1"; ConnectInfo.RPMSDataTable(sCommandText, "Provider", m_dsGlobal); Debug.Write("LoadGlobalRecordsets -- Provider loaded\n"); - setStatusDelegate(statusConst + " Clinic Stops"); //Build the CLINIC_STOP table + //Table #15 + setProgressDelegate(15); + setStatusDelegate(statusConst + " Clinic Stops"); // sCommandText = "SELECT BMXIEN, CODE, NAME FROM CLINIC_STOP"; //SMH sCommandText = "SELECT BMXIEN, AMIS_REPORTING_STOP_CODE, NAME FROM CLINIC_STOP"; ConnectInfo.RPMSDataTable(sCommandText, "ClinicStop", m_dsGlobal); Debug.Write("LoadGlobalRecordsets -- ClinicStop loaded\n"); - setStatusDelegate(statusConst + " Holiday"); //Build the HOLIDAY table + //Table #16 + setProgressDelegate(16); + setStatusDelegate(statusConst + " Holiday"); sCommandText = "SELECT NAME, DATE FROM HOLIDAY WHERE DATE > '" + DateTime.Today.ToShortDateString() + "'"; ConnectInfo.RPMSDataTable(sCommandText, "HOLIDAY", m_dsGlobal); Debug.Write("LoadingGlobalRecordsets -- Holidays loaded\n"); @@ -567,17 +603,27 @@ namespace IndianHealthService.ClinicalScheduling //Save the xml schema //m_dsGlobal.WriteXmlSchema(@"..\..\csSchema20060526.xsd"); //---------------------------------------------- - + setStatusDelegate("Setting Receive Timeout"); _current.m_ConnectInfo.ReceiveTimeout = 30000; //30-second timeout #if DEBUG _current.m_ConnectInfo.ReceiveTimeout = 600000; //longer timeout for debugging #endif - _current.m_ConnectInfo.SubscribeEvent("BSDX SCHEDULE"); - _current.m_ConnectInfo.SubscribeEvent("BSDX CALL WORKSTATIONS"); - _current.m_ConnectInfo.SubscribeEvent("BSDX ADMIN MESSAGE"); - _current.m_ConnectInfo.SubscribeEvent("BSDX ADMIN SHUTDOWN"); + // Event Subsriptions + setStatusDelegate("Subscribing to Server Events"); + //Table #17 + setProgressDelegate(17); + _current.m_ConnectInfo.SubscribeEvent("BSDX SCHEDULE"); + //Table #18 + setProgressDelegate(18); + _current.m_ConnectInfo.SubscribeEvent("BSDX CALL WORKSTATIONS"); + //Table #19 + setProgressDelegate(19); + _current.m_ConnectInfo.SubscribeEvent("BSDX ADMIN MESSAGE"); + //Table #20 + setProgressDelegate(20); + _current.m_ConnectInfo.SubscribeEvent("BSDX ADMIN SHUTDOWN"); _current.m_ConnectInfo.EventPollingInterval = 5000; //in milliseconds _current.m_ConnectInfo.EventPollingEnabled = true; @@ -585,6 +631,8 @@ namespace IndianHealthService.ClinicalScheduling //Close Splash Screen closeSplashDelegate(); + + return true; } diff --git a/cs/bsdx0200GUISourceCode/ClinicalScheduling.csproj.user b/cs/bsdx0200GUISourceCode/ClinicalScheduling.csproj.user index 4f1737c..ffde694 100644 --- a/cs/bsdx0200GUISourceCode/ClinicalScheduling.csproj.user +++ b/cs/bsdx0200GUISourceCode/ClinicalScheduling.csproj.user @@ -36,7 +36,7 @@ Project - /s=10.161.20.25 /p=9280 /a=s.habiel /v=catdog.55 + /s=192.168.56.101 /p=9260 /a=shabiel12 /v=catdog.66 C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\IEExec.exe diff --git a/cs/bsdx0200GUISourceCode/ClinicalScheduling.suo b/cs/bsdx0200GUISourceCode/ClinicalScheduling.suo index 70ce019a0794095dde56c7f851d0966e25925803..00fcae6477d0a738777ae903e2b2e3e241f90e54 100644 GIT binary patch delta 8489 zcmZu$4P2B})}M197$+8KK$ayU91#f>k&uujmqtWFUKUwo%M@v}k2Nzxos7tIOkXo2 zL#}bmjED$7@&g4KMAOmSGPNYLFC!zeGIL#Wsmv|i|GhJ#+xvU{Ir^M)&pr3t^L_7i zt?uh;>f1CkAkc9~-ou^EvjdF2^m6mVq3@e1ocH#lq0$*y7#LpBEoCr2j_Z|;rm=tKR~r|gY8YBmi7)$e^&gVtL@GdrHW z@Zj-p=3Gb_x?^2z?eILF`lRUB>`Af*a??;zCu44osIIA?6d5{lZcP}yDXk*|}f1UP$HK7DZv=WfNcO5y#2Jq0wTz z44xlD!+7BU@d7(C$QC#ko3YDbx31*48^mhqC=ZZ@gTrK5R)BPlnemDWWUNzbg5=km>TL5@EExvcwl6y43E2Z{%<%M7#0v>Zgz>PdQ9`5znw^oDmKMZs2`W#BCfqm^^aUoiVaEe>K}O$;MmCL`WZ# zX$&||lZ#eOkeluZrz3LTz8!MZ9nqXUP)z5-H$;YX-EM|~=CLhX1jyvcadK6rQ?8hl zpbX%wo)pF5(V~E@H(?9c$$w6Mforc5xw7l~NV*5$Wz4OmujRhKUC(Qu5^-|@96hy$zqrvDynWgNy0$B( zWWd2qhbe2!gfSt|VCePNH?P0Dt}pfXdc1S?csVBMrsm$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fLGx(*8bUngnHkN5M?WtyUsI*fMVMOTE zFOPQkwcQ&!QV<-AVS++)<6L`UWzk;TCgXluy7r8d_PtRuW={(oeH>=wprdf>$dz7S zuw1v>DU)77prAVqAd0j~KaXx~aqDgXh;Vt@r;M#Av(<$*{tb~HUksX=yH(8zz*gDU z9>U4x@SKyOB99LY!UZHsij@}*5;>eYNTkWrn`5~zpCS}HAFfN66PFAThk2t@WU_s{ z$dmc+Wg^F{943A%{WtmfMmrvVR_P}JZWt=!)aybi#~u|i(w|nqJ-3LF^rUb9P%)l3 z&mpS0;y0q6T@FwlbBIrHS-oh`GwKdAC>VECtMrRbnM*{}dV;A&-t@yi*dC3GPIZf? zURUn*J?5aHgtOMTdsSb?)Do=9$$p(CT&8wK2C+E!ZafUleBgfM==I`S-n~xzFV|$?(gPJIfgChwz)d+tZy;lB$zk7j9=B6^A2ePXMS9T_R`+1YRCMND&&$J2r?!Uhgz2a0`9aC}SCWM;l4> z=byiAoOQL4?1SBo5c@|M*7gRG84|P!e70ylT(M1b1vLTQYVxgkQA{xgSb@OXr~Ewo z`t}_nBiv?r4VVJ~lKtY{AvVh^!0Zk%`9OGrwgY~{q&V||$Pu_EPLJV8te-n zZa9hB6mHRfdHTYu4Tsf=LefN2cHHKVST*?#N#+zs~>1JaD|K>U)#y9wOqn>zJhEd2%?=Ti{ce-)8 XblrZhFYI-(hB&=kMEWALA?UvWcRNFa diff --git a/cs/bsdx0200GUISourceCode/DSplash.cs b/cs/bsdx0200GUISourceCode/DSplash.cs index 24a537d..f873b03 100644 --- a/cs/bsdx0200GUISourceCode/DSplash.cs +++ b/cs/bsdx0200GUISourceCode/DSplash.cs @@ -16,6 +16,7 @@ namespace IndianHealthService.ClinicalScheduling private System.Windows.Forms.Label lblStatus; private Label lblVersion; private Label label2; + private ProgressBar progressBar1; /// /// Required designer variable. /// @@ -61,6 +62,7 @@ namespace IndianHealthService.ClinicalScheduling this.lblStatus = new System.Windows.Forms.Label(); this.lblVersion = new System.Windows.Forms.Label(); this.label2 = new System.Windows.Forms.Label(); + this.progressBar1 = new System.Windows.Forms.ProgressBar(); this.SuspendLayout(); // // label1 @@ -109,12 +111,21 @@ namespace IndianHealthService.ClinicalScheduling this.label2.TabIndex = 6; this.label2.Text = "VISTA"; // + // progressBar1 + // + this.progressBar1.Location = new System.Drawing.Point(18, 207); + this.progressBar1.Name = "progressBar1"; + this.progressBar1.Size = new System.Drawing.Size(458, 14); + this.progressBar1.Style = System.Windows.Forms.ProgressBarStyle.Continuous; + this.progressBar1.TabIndex = 7; + // // DSplash // this.AutoScaleBaseSize = new System.Drawing.Size(5, 13); this.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(192))))); this.ClientSize = new System.Drawing.Size(488, 252); this.ControlBox = false; + this.Controls.Add(this.progressBar1); this.Controls.Add(this.label2); this.Controls.Add(this.lblVersion); this.Controls.Add(this.lblStatus); @@ -134,6 +145,7 @@ namespace IndianHealthService.ClinicalScheduling public delegate void dSetStatus(string sStatus); public delegate void dAny(); + public delegate void dProgressBarSet(int number); public void SetStatus(string sStatus) { @@ -144,9 +156,7 @@ namespace IndianHealthService.ClinicalScheduling return; } - System.Diagnostics.Debug.Assert(this.InvokeRequired == false); this.lblStatus.Text = sStatus; - this.Refresh(); } private void DSplash_Load(object sender, System.EventArgs e) @@ -165,6 +175,31 @@ namespace IndianHealthService.ClinicalScheduling dAny d = new dAny(this.Hide); this.Invoke(d); } + + public void RemoteProgressBarMaxSet(int max) + { + if (this.InvokeRequired == true) + { + dProgressBarSet d = new dProgressBarSet(RemoteProgressBarMaxSet); + this.Invoke(d, new object[] { max }); + return; + } + + this.progressBar1.Maximum = max; + } + + public void RemoteProgressBarValueSet(int val) + { + if (this.InvokeRequired == true) + { + dProgressBarSet d = new dProgressBarSet(RemoteProgressBarValueSet); + this.Invoke(d, new object[] { val }); + return; + } + + this.progressBar1.Value = val; + } + }