//AB/ Project CM About //AB/ Object oIDE_Project is a Dialog_Project //AB/ Set ProjectName to "CM About" //AB/ Set ProjectFileName to "RDCAbout.DG" //AB/ Set GenerateFileName to "NONAME1" //AB/ Set Size to 266 352 // Project Object Structure // oAboutDialog is a cRDSDbModalPanel // oBox is a Container3d // oAboutGraphic is a BitmapContainer // oAboutEdit is a cRDSEdit // oOkButton is a cRDSButton // oUpdate_bn is a cRDSButton // oBuyProduct_bn is a cRDSButton // oWebSite_bn is a cRDSButton // oNewsGroup_bn is a cRDSButton // oSysInfoButton is a cRDSButton // oNewsGroup_bn is a cBitmapButton (Duplicate object name) // oWebSite_bn is a cBitmapButton (Duplicate object name) // oSysInfo_bn is a cBitmapButton // oBuyProduct_bn is a cBitmapButton (Duplicate object name) // oUpdate_bn is a cBitmapButton (Duplicate object name) // oOkButton is a cBitmapButton (Duplicate object name) // Register all objects Register_Object oAboutDialog Register_Object oAboutEdit Register_Object oAboutGraphic Register_Object oBox Register_Object oBuyProduct_bn Register_Object oNewsGroup_bn Register_Object oOkButton Register_Object oSysInfo_bn Register_Object oSysInfoButton Register_Object oUpdate_bn Register_Object oWebSite_bn //AB-StoreTopStart Use LanguageText.pkg Use DfBitmap.Pkg //Use cRdcLicence.pkg // SOUP component class Use ShellExecute.pkg Use CrossMergeLicenseServer.h // Header file with define statements Use cGetSetVersionNumber.pkg // Class for getting version number. //AB-StoreTopEnd //AB-IgnoreStart Use cRDSDbModalPanel.pkg Use Windows.pkg Use dfbitmap.pkg Use cRDSEdit.pkg Use cRDSButton.pkg Use cBitmapButton.pkg //AB-IgnoreEnd Object oAboutDialog is a cRDSDbModalPanel //AB-StoreTopStart Use SysInfoDialog.Dg //AB-StoreTopEnd Set Border_Style to Border_Thick Set Label to "About CrossMerge" Set Location to 1 1 Set Size to 255 343 Set piMinSize to 204 343 //AB-DDOStart //AB-DDOEnd Object oBox is a Container3d //AB-StoreTopStart Function CrossMergeVersionInfo Returns String Integer hoVersionInfo iVersionMajor iVersionMinor iVersionRelease iVersionBuild Boolean bIncluded If (ghoApplication <> 0) Begin Get phoVersionInfo Of ghoApplication To hoVersionInfo If (hoVersionInfo <> 0) Begin Get pbIncluded Of hoVersionInfo To bIncluded If (bIncluded) Begin Get piVersionMajor Of hoVersionInfo To iVersionMajor Get piVersionMinor Of hoVersionInfo To iVersionMinor Get piVersionRelease Of hoVersionInfo To iVersionRelease Get piVersionBuild Of hoVersionInfo To iVersionBuild Function_Return ((SFormat(C_$VERSION + ": %1.%2.%3.", iVersionMajor, iVersionMinor, iVersionRelease)) * "Build No: " + String(iVersionBuild)) End End End End_Procedure // CrossMergeVersionInfo Procedure AddLine String sVal Handle ho Integer iLine Move (oAboutEdit(Self)) To ho Move (Line_Count(ho)) To iLine Set Value Of ho Item iLine To sVal End_Procedure // Add_Line Procedure ReadInfoFile String sFileName String sHelpPath Get psHelpPath Of (phoWorkspace(ghoApplication)) To sHelpPath Direct_Input sFilename If Not (Seqeof) Begin Close_Input Send Read Of oAboutEdit sFilename End End_Procedure // ReadInfoFile //AB-StoreTopEnd Set Size to 156 328 Set Location to 5 5 Set Color to clWindow Set peAnchors to anAll Set Border_Style to Border_ClientEdge Object oAboutGraphic is a BitmapContainer Set Size to 39 48 Set Location to 4 2 Set Color to clWindow Set Bitmap to "Cm48x48.bmp/t3d" Set Border_Style to Border_None Set Bitmap_Style to Bitmap_Center End_Object // oAboutGraphic Object oAboutEdit is a cRDSEdit Set Size to 153 275 Set Location to 0 51 Set peAnchors to anAll Set Border_Style to Border_None //AB-StoreStart Set Read_Only_State To True //AB-StoreEnd End_Object // oAboutEdit //AB-StoreStart Procedure DoUpdateAbout String sVersion Integer iVersionMajor iVersionMinor iVersionRelease Version_Information iVersionMajor iVersionMinor iVersionRelease Send AddLine "" Send AddLine (psProduct(ghoApplication) * psProgram(ghoApplication) * "-" * psLicenseType(ghoApplication)) Send AddLine "" Get CrossMergeVersionInfo To sVersion Send AddLine sVersion Send AddLine "Copyright 2001-2004 RDC Tools International. Portions Copyright Data Access Worldwide." //Send AddLine "E-mail: support@crossmerge.com" Send AddLine ("Support:" * CM_NewsGroup) Send AddLine "" Send AddLine "'CrossMerge', 'CrossMerge Builder' and 'CrossMerge Engine' are trademarks of RDC Tools International" Send AddLine "" Send AddLine ("This tool was created with Visual DataFlex" * String(iVersionMajor) + "." + String(iVersionMinor) * "from Data Access Worldwide. Visit www.dataaccess.com for a free evaluation copy of Visual DataFlex.") Send AddLine "" Send AddLine ("Licensed to:" * psName(ghoApplication)) Send AddLine ("Serial no:" * String(psSerial(ghoApplication))) Send AddLine ("Licensed users:" * String(piUsers(ghoApplication))) Send AddLine "" Send ReadInfoFile "CrossMerge.inf" End_Procedure // DoUpdateAbout //AB-StoreEnd End_Object // oBox Object oOkButton is a cRDSButton Set Label to "&Close" Set Location to 166 283 Set Status_Help to "Close this panel" Set peAnchors to anBottomRight Set Default_State to TRUE //AB-StoreStart Procedure OnClick Send Close_Panel End_Procedure // OnClick //AB-StoreEnd End_Object // oOkButton Object oUpdate_bn is a cRDSButton Set Label to "&Update Check" Set Size to 14 54 Set Location to 166 5 Set Status_Help to "Check if there is a later version of CrossMerge available. You need to have Internet enabled on the machine." Set peAnchors to anBottomLeft //AB-StoreStart Procedure OnClick String sRetval Integer iRetval // Get YesNo_Box "You need to have a working Internet connection on your machine to be able to check if a more recent version of CrossMerge is available. Continue?" To iRetval // If (iRetval = MBR_No) Procedure_Return Send DoCheckUpdate End_Procedure // OnClick Function CrossMergeVersionInfo Returns String Integer hoVersionInfo iVersionMajor iVersionMinor iVersionRelease iVersionBuild Boolean bIncluded If (ghoApplication <> 0) Begin Get phoVersionInfo Of ghoApplication To hoVersionInfo If (hoVersionInfo <> 0) Begin Get pbIncluded Of hoVersionInfo To bIncluded If (bIncluded) Begin Get piVersionMajor Of hoVersionInfo To iVersionMajor Get piVersionMinor Of hoVersionInfo To iVersionMinor Get piVersionRelease Of hoVersionInfo To iVersionRelease Get piVersionBuild Of hoVersionInfo To iVersionBuild Function_Return (SFormat("%1.%2.%3.%4", iVersionMajor, iVersionMinor, iVersionRelease, iVersionBuild)) End // If (bIncluded) Begin End // If (hoVersionInfo <> 0) Begin End // If (ghoApplication <> 0) Begin End_Procedure // CrossMergeVersionInfo Procedure DoCheckUpdate String sCustomerVersion sVersion sUser sPWord sOk sError sHeaderText sMessageText Integer iType iCustomerVersion iVersion iCustomerBuild iBuild iPos iRetval iGetSet iError Handle ho Send StartWorkingMessage "Retrieving version information from WEB-service..." Get CrossMergeVersionInfo To sCustomerVersion Move 0 To iGetSet Move "" To sVersion Get Create U_cGetSetVersionNumber To ho Send DoGetSetVersionNumber Of ho iGetSet sVersion Get piError Of ho To iError Get psError Of ho To sError Get psHeaderText Of ho To sHeaderText Get psMessageText Of ho To sMessageText Send Destroy Of ho Send StopWorkingMessage //Showln "webservice sVersion = " sVersion " current Builder version = " sCustomerVersion If (iError <> CM_Err_Ok) Begin Send Info_Box (String(sError)) Procedure_Return End // If (iError <> CM_Err_Ok) Begin Move sError To sVersion If (sCustomerVersion >= sVersion) Begin Send Info_Box "You have the latest version of CrossMerge." Procedure_Return End Else Begin Move MBR_No To iRetval // Remove the first two "." in the version: Move (Replace(".", sCustomerVersion, "")) To sCustomerVersion Move (Replace(".", sCustomerVersion, "")) To sCustomerVersion Move (Replace(".", sVersion, "")) To sVersion Move (Replace(".", sVersion, "")) To sVersion Move (Pos(".", sCustomerVersion)) To iPos Move (Left(sCustomerVersion, (iPos - 1))) To iCustomerVersion Move (Mid(sCustomerVersion, 10, (iPos + 1))) To iCustomerBuild Move (Pos(".", sVersion)) To iPos Move (Left(sVersion, (iPos - 1))) To iVersion Move (Mid(sVersion, 10, (iPos + 1))) To iBuild //Showln "iVersion = " iVersion " iCustomerVersion = " iCustomerVersion //Showln "iBuild = " iBuild " iCustomerBuild = " iCustomerBuild If (iVersion > iCustomerVersion) ; Get YesNo_Box "There is a later version of CrossMerge available. Do you want to download it now?" ; sHeaderText To iRetval Else If (iBuild > iCustomerBuild) ; Get YesNo_Box "There is a later build of CrossMerge available. A new build usually means bugs that has been fixed, but there are no new features added. Do you want to download it now?" ; sHeaderText To iRetval If (iRetval = MBR_No) Procedure_Return Send DoStartDocument "open" (String(CMLS_CrossMerge_Host) + String(CMLS_Dowload_Path_Version3)) "" "" End // Else Begin End_Procedure // DoCheckUpdate //AB-StoreEnd End_Object // oUpdate_bn Object oBuyProduct_bn is a cRDSButton Set Label to "&Buy Product" Set Location to 166 61 Set Status_Help to "Display a list of CrossMerge distributors in your web-browser. You need to have Internet enabled on the machine." Set peAnchors to anBottomLeft //AB-StoreStart Procedure OnClick Send DoStartDocument "open" (String(CMLS_CrossMerge_Host) + String(CMLS_Server_Host_Partners)) "" "" End_Procedure // OnClick //AB-StoreEnd End_Object // oBuyProduct_bn Object oWebSite_bn is a cRDSButton Set Label to "&Web Site" Set Location to 166 113 Set Status_Help to "Open www.Crossmerge.com in your web-browser. You need to have Internet enabled on the machine." Set peAnchors to anBottomLeft //AB-StoreStart Procedure OnClick Send DoStartDocument "open" CMLS_CrossMerge_Host "" "" End_Procedure // OnClick //AB-StoreEnd End_Object // oWebSite_bn Object oNewsGroup_bn is a cRDSButton Set Label to "&Newsgroup" Set Location to 166 165 Set peAnchors to anBottomLeft //AB-StoreStart Procedure OnClick Send DoStartDocument "open" CM_NewsGroup "" "" End_Procedure // OnClick //AB-StoreEnd End_Object // oNewsGroup_bn Object oSysInfoButton is a cRDSButton Set Label to "&System info" Set Location to 166 216 Set Status_Help to "Display system information about software and hardware." Set peAnchors to anBottomLeft //AB-StoreStart Procedure OnClick Send Popup_Modal Of oSystemInformationDialog End_Procedure // OnClick //AB-StoreEnd End_Object // oSysInfoButton Object oNewsGroup_bn is a cBitmapButton Set Label to "&Newsgroup" Set Size to 14 59 Set Location to 188 187 Set peAnchors to anBottomLeft Set Bitmap to "NewsGroups16.bmp" Set piTransparentColor to clFuchsia //AB-StoreStart Procedure OnClick Send DoStartDocument "open" CM_NewsGroup "" "" End_Procedure // OnClick //AB-StoreEnd End_Object // oNewsGroup_bn Object oWebSite_bn is a cBitmapButton Set Label to "&Web Site" Set Size to 14 51 Set Location to 188 134 Set Status_Help to "Open www.Crossmerge.com in your web-browser. You need to have Internet enabled on the machine." Set peAnchors to anBottomLeft Set Bitmap to "Inet16.bmp" Set piTransparentColor to clFuchsia //AB-StoreStart Procedure OnClick Send DoStartDocument "open" CMLS_CrossMerge_Host "" "" End_Procedure // OnClick //AB-StoreEnd End_Object // oWebSite_bn Object oSysInfo_bn is a cBitmapButton Set Label to "&System Info" Set Size to 14 58 Set Location to 188 248 Set Status_Help to "Display system information about software and hardware." Set peAnchors to anBottomLeft Set Bitmap to "Help16x16.bmp" Set piTransparentColor to clFuchsia //AB-StoreStart Procedure OnClick End_Procedure // OnClick //AB-StoreEnd End_Object // oSysInfo_bn Object oBuyProduct_bn is a cBitmapButton Set Label to "&Buy Product" Set Size to 14 58 Set Location to 188 75 Set Status_Help to "Display a list of CrossMerge distributors in your web-browser. You need to have Internet enabled on the machine." Set peAnchors to anBottomLeft Set Bitmap to "Inet16.bmp" Set piTransparentColor to clFuchsia //AB-StoreStart Procedure OnClick Send DoStartDocument "open" (String(CMLS_CrossMerge_Host) + String(CMLS_Server_Host_Partners)) "" "" End_Procedure // OnClick //AB-StoreEnd End_Object // oBuyProduct_bn Object oUpdate_bn is a cBitmapButton Set Label to "&Update Check" Set Size to 14 67 Set Location to 188 6 Set Status_Help to "Check if there is a later version of CrossMerge available. You need to have Internet enabled on the machine." Set peAnchors to anBottomLeft Set Bitmap to "UpDate16.bmp" Set piTransparentColor to clFuchsia //AB-StoreStart Procedure OnClick Send DoStartDocument "open" (String(CMLS_CrossMerge_Host) + String(CMLS_Server_Host_Partners)) "" "" End_Procedure // OnClick //AB-StoreEnd End_Object // oUpdate_bn Object oOkButton is a cBitmapButton Set Label to "&Close" Set Size to 14 50 Set Location to 205 283 Set Status_Help to "Close this panel" Set peAnchors to anBottomRight Set Bitmap to "Cancel16.bmp" Set piTransparentColor to clFuchsia //AB-StoreStart Procedure OnClick Send Close_Panel End_Procedure // OnClick //AB-StoreEnd End_Object // oOkButton //AB-StoreStart // Tell the object what to do if the following keys are pressed. On_Key kCancel Send KeyAction Of oOkButton On_Key Key_Alt+Key_C Send KeyAction Of oOkButton On_Key Key_Alt+Key_S Send KeyAction Of oSysInfoButton On_Key Key_Alt+Key_W Send KeyAction Of oWebSite_bn On_Key Key_Alt+Key_N Send KeyAction Of oNewsGroup_bn On_Key Key_Alt+Key_B Send KeyAction Of oBuyProduct_bn On_Key Key_Alt+Key_U Send KeyAction Of oUpdate_bn // Make the panel show centered on the screen Set Locate_Mode To CENTER_ON_SCREEN //AB-StoreEnd End_Object // oAboutDialog //AB-StoreStart // This method name is send from the HELPA_PM.INC file when the about // option is selected Procedure Activate_About Send Popup Of (oAboutDialog(Self)) End_Procedure // Activate_About // Send by the main program after the view has been activated. // Must be in this order because it is then the Protection Plus // logic is activated and info is displayed in this dialog. Procedure DoUpdateAbout Handle ho Move (oBox(oAboutDialog(Self))) To ho Send DoUpdateAbout Of ho End_Procedure // DoUpdateAbout //AB-StoreEnd //AB/ End_Object // oIDE_Project