- Timestamp:
- Dec 12, 2010, 2:44:49 AM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Scheduling/trunk/cs/bsdx0200GUISourceCode/CGDocumentManager.cs
r1011 r1039 324 324 m_ds.Refresh(); 325 325 326 DataTable ver = _dal.GetVersion("BSDX"); //sCmd, "VersionInfo", m_dsGlobal);326 DataTable ver = _dal.GetVersion("BSDX"); 327 327 ver.TableName = "VersionInfo"; 328 328 m_dsGlobal.Tables.Add(ver); 329 330 //Keep the following commented code for future use: 329 331 330 //How to extract the version numbers: 332 //DataTable dtVersion = m_dsGlobal.Tables["VersionInfo"]; 333 //Debug.Assert(dtVersion.Rows.Count == 1); 334 //DataRow rVersion = dtVersion.Rows[0]; 335 //string sMajor = rVersion["MAJOR_VERSION"].ToString(); 336 //string sMinor = rVersion["MINOR_VERSION"].ToString(); 337 //string sBuild = rVersion["BUILD"].ToString(); 338 //decimal fBuild = Convert.ToDecimal(sBuild); 331 DataTable dtVersion = m_dsGlobal.Tables["VersionInfo"]; 332 Debug.Assert(dtVersion.Rows.Count == 1); 333 DataRow rVersion = dtVersion.Rows[0]; 334 string sMajor = rVersion["MAJOR_VERSION"].ToString(); 335 string sMinor = rVersion["MINOR_VERSION"].ToString(); 336 string sBuild = rVersion["BUILD"].ToString(); 337 decimal fBuild = Convert.ToDecimal(sBuild); 338 339 //Make sure that the server is running the same version the client is. 340 Version x = System.Reflection.Assembly.GetExecutingAssembly().GetName().Version; 341 342 //if version numbers mismatch, don't continue. 343 //TODO: For future: Include in v. 1.5 344 /* 345 if (!(x.Major.ToString() == sMajor && x.Minor.ToString() + x.Build.ToString() == sMinor)) 346 { 347 MessageBox.Show( 348 "Server runs version " + sMajor + "." + sMinor + "\r\n" + 349 "You are running " + x.ToString() + "\r\n\r\n" + 350 "Major, Minor and Build versions must match", 351 "Version Mismatch"); 352 m_ds.Close(); 353 return; 354 } 355 */ 356 339 357 340 358 //Change encoding
Note:
See TracChangeset
for help on using the changeset viewer.