Use Windows.pkg Use DFClient.pkg Use cForm.pkg Use RegCheck2.pkg Activate_View Activate_oRegCheck2_View for oRegCheck2_View Object oRegCheck2_View is a dbView Set Border_Style to Border_Thick Set Size to 311 479 Set Location to 0 0 Set Label to "RegCheck 2 Test View" Set Maximize_Icon to True Object oViewLogFile_btn is a Button Set Size to 14 74 Set Location to 289 397 Set Label to "View Logfile" Set psToolTip to ("Open the logfile (" - CS_LogFileName - ") with the Windows associated program.") Set peAnchors to anNone Procedure OnClick String sPath Get psDataPath of (phoWorkspace(ghoApplication)) to sPath Get PathAtIndex of (phoWorkspace(ghoApplication)) sPath 1 to sPath Runprogram Shell Background (sPath - "\" - CS_LogFileName) End_Procedure End_Object Object oVersionInfo_grp is a Group Set Size to 116 304 Set Location to 41 9 Set Label to "Operative System Properties" Set peAnchors to anNone Object oWindowsVersion is a cForm Set Size to 13 231 Set Location to 11 66 Set Label to "Windows Version" Set psToolTip to "Full Windows version description" Set peAnchors to anTopLeftRight End_Object Object oVersionNumber is a cForm Set Size to 13 231 Set Location to 26 66 Set Label to "Version Number" Set psToolTip to "piMajorVersion and piMinorVersion" Set peAnchors to anTopLeftRight End_Object Object oEdition is a cForm Set Size to 13 231 Set Location to 41 66 Set Label to "Edition" Set psToolTip to "The Edition string contains specific details about the platform that cannot be enabled as a role. So 'Home' edition or 'Datacenter' edition are good examples." Set peAnchors to anTopLeftRight End_Object Object oBuildNumber is a cForm Set Size to 13 231 Set Location to 56 66 Set Label to "Build Number" Set psToolTip to "Identifies the build number of the operating system" Set peAnchors to anTopLeftRight End_Object Object oServicePack is a cForm Set Size to 13 96 Set Location to 71 66 Set Label to "Service Pack" Set psToolTip to "Identifies the major version number of the latest Service Pack installed on the system. For example, for Service Pack 3, the major version number is 3. If no Service Pack has been installed, the value is zero." Set peAnchors to anNone End_Object Object oMinServicePack is a cForm Set Size to 13 66 Set Location to 71 231 Set Label to "Min Service Pack" Set psToolTip to "piMinxxx_ServicePack. Minimum service pack that is required for the current windows version. If it is lower than the 'Service Pack' version to the left AND pbTestServicePack = True, user will get informed that this service pack needs to be installed before the program can be run." Set peAnchors to anTopLeftRight End_Object Object oFeatures is a cForm Set Size to 13 231 Set Location to 86 66 Set Label to "Features" Set psToolTip to "The psSuite string only contains features which can be enabled or not, so it is NOT a direct mapping to piSuiteMask. An example of this is if you are in a remote desktop session or not." Set peAnchors to anTopLeftRight End_Object Object oX64OS is a CheckBox Set Size to 13 230 Set Location to 102 66 Set Label to "X64 version" Set psToolTip to "pbX64 is set to true if your host OS is x64 (64-bits)" End_Object Object oNTServer is a CheckBox Set Size to 13 230 Set Location to 102 161 Set Label to "Windows Server" Set psToolTip to "Running windows version is a server version." End_Object Object oWindowsHome is a CheckBox Set Size to 13 230 Set Location to 102 231 Set Label to "Windows Home" Set psToolTip to "The Windows HOME version is NOT a recommended platform for running business applications (networking is limited)." End_Object End_Object Object oComputerAndUserInfo_grp is a Group Set Size to 44 304 Set Location to 160 9 Set peAnchors to anNone Set Label to "Computer and User Info" Object oComputerName is a cForm Set Size to 13 231 Set Location to 10 66 Set Label to "Computer Name" Set peAnchors to anTopLeftRight End_Object Object oUserLoginName is a cForm Set Size to 13 231 Set Location to 25 66 Set Label to "User Login Name" Set psToolTip to "The user network login name" Set peAnchors to anTopLeftRight End_Object End_Object Object oOtherClassProperties_grp is a Group Set Size to 50 304 Set Location to 207 9 Set peAnchors to anNone Set Label to "Standard RegCheck2 Class Properties" Object oBruteForce is a CheckBox Set Size to 13 230 Set Location to 10 66 Set Label to "Driver Brute Force" Set psToolTip to "pbDriverBruteForce. To force a change of the registry even if there are more than the 'DATAFLEX' database driver loaded. It is possible that an (accounting) Pervasive table gets queried for info while the rest of the tables are in the embedded DataFlex database." End_Object Object oReportStateOnly is a CheckBox Set Size to 13 230 Set Location to 10 161 Set Label to "Report State Only" Set psToolTip to "pbReportStateOnly. Set to true if you only want to report current registry settings - but not try to change them." End_Object Object oAdminRights is a CheckBox Set Size to 13 230 Set Location to 10 231 Set Label to "Admin Rights" Set psToolTip to "pbAdminRights. Is the program run with administrator rights?" End_Object Object oHighDataIntegrity is a CheckBox Set Size to 13 230 Set Location to 22 66 Set Label to "High Data Integrity" Set psToolTip to "pbChangeHighDataIntegrity. If True the DF_HIGH_DATA_INTEGRITY will be set to True. If false the DF_HIGH_DATA_INTEGRITY is not changed." End_Object Object oTestServicePack is a CheckBox Set Size to 13 230 Set Location to 22 161 Set Label to "Test Service Pack" Set psToolTip to "pbTestServicePack. Should we check for the service pack and if it is to low deny the running of the application?" End_Object Object oSilentMode is a CheckBox Set Size to 13 230 Set Location to 22 231 Set Label to "Silent Mode" Set psToolTip to "pbSilentMode. Ask user before making changes?" End_Object Object oDoServerRegistryChanges is a CheckBox Set Size to 13 230 Set Location to 35 66 Set Label to "Do Server Changes" Set psToolTip to "pbDoServerRegistryChanges. Try to make changes on NT machines although it might not be possible due to unsufficient user rights. User will get confirmation if unsuccessful" End_Object End_Object // Note: Object needs to be after the oRunChangeProgram_btn object. Object oImportantClassProperties_grp is a Group Set Size to 25 304 Set Location to 262 9 Set Label to "Important RegCheck2 Class Properties" Set peAnchors to anNone Object oRegistryChangesNeeded is a CheckBox Set Size to 13 230 Set Location to 10 66 Set Label to "Registry Changes Needed" Set psToolTip to "pbRegistryChangesNeeded. This property is set to true when at least one registry change is needed. Registry changes can be done by clicking the 'Run Change Program' button." Procedure OnChange Boolean bState Get Checked_State to bState If (bState = True) Begin Set Color to clRed End Else Begin Set Color to clBtnFace End End_Procedure End_Object Object oServicePackUpdateNeeded is a CheckBox Set Size to 13 230 Set Location to 10 161 Set Label to "Service Pack Updates Needed" Set psToolTip to "pbServicePackUpdateNeeded. New Service Pack(s) needs to be installed." Procedure OnChange Boolean bState Get Checked_State to bState If (bState = True) Begin Set Color to clRed End Else Begin Set Color to clBtnFace End End_Procedure End_Object End_Object Object oRegChangesToDo_grp is a Group Set Size to 163 152 Set Location to 41 319 Set Label to "Registry Changes (1=Change Needed)" Object oList is a List Set Size to 148 140 Set Location to 11 6 // The code should work with VDF 11 and later. Thus // CodeJock controls cannot be used. Procedure DoFillList tRegChangesToDo RegChangesToDo Handle ho String sValue Get ptRegChangesToDo of ghoRegCheck2 to RegChangesToDo Move oList to ho Send Delete_Data of ho Move RegChangesToDo.bOplocksDisabled to sValue Send Add_Item of ho Msg_None ("OplocksDisabled = " + sValue) Move RegChangesToDo.bUseOpportunisticLocking to sValue Send Add_Item of ho Msg_None ("UseOpportunisticLocking = " + sValue) Move RegChangesToDo.bDirectoryCacheLifetime to sValue Send Add_Item of ho Msg_None ("DirectoryCacheLifetime = " + sValue) Move RegChangesToDo.bFileInfoCacheLifetime to sValue Send Add_Item of ho Msg_None ("FileInfoCacheLifetime = " + sValue) Move RegChangesToDo.bFileNotFoundCacheLifetime to sValue Send Add_Item of ho Msg_None ("FileNotFoundCacheLifetime = " + sValue) End_Procedure End_Object End_Object Procedure RetrieveOSInfo Boolean bState String sValue String sMajor String sMinor Get psOSVersion of ghoRegCheck2 to sValue Set Value of oWindowsVersion to sValue Get piMajorVersion of ghoRegCheck2 to sMajor Get piMinorVersion of ghoRegCheck2 to sMinor Set Value of oVersionNumber to (Trim(sMajor) + "." + Trim(sMinor)) Get piBuildNumber of ghoRegCheck2 to sValue Set Value of oBuildNumber to sValue Get psEdition of ghoRegCheck2 to sValue Set Value of oEdition to sValue Get psCSDVersion of ghoRegCheck2 to sValue Set Value of oServicePack to sValue Get CurrentMinServicePack of ghoRegCheck2 to sValue Set Value of oMinServicePack to sValue Get psSuite of ghoRegCheck2 to sValue Set Value of oFeatures to sValue Get pbX64 of ghoRegCheck2 to bState Set Checked_State of oX64OS to bState Get pbWindowsHome of ghoRegCheck2 to bState Set Checked_State of oWindowsHome to bState Get pbNTServer of ghoRegCheck2 to bState Set Checked_State of oNTServer to bState Get psComputerName of ghoRegCheck2 to sValue Set Value of oComputerName to sValue Get psUserLoginName of ghoRegCheck2 to sValue Set Value of oUserLoginName to sValue Get pbDriverBruteForce of ghoRegCheck2 to bState Set Checked_State of oBruteForce to bState Get pbReportOnlyState of ghoRegCheck2 to bState Set Checked_State of oReportStateOnly to bState Get pbAdminRights of ghoRegCheck2 to bState Set Checked_State of oAdminRights to bState Get pbChangeHighDataIntegrity of ghoRegCheck2 to bState Set Checked_State of oHighDataIntegrity to bState Get pbSilentMode of ghoRegCheck2 to bState Set Checked_State of oSilentMode to bState Get pbDoServerRegistryChanges of ghoRegCheck2 to bState Set Checked_State of oDoServerRegistryChanges to bState Get pbTestServicePack of ghoRegCheck2 to bState Set Checked_State of oTestServicePack to bState Get pbRegistryChangesNeeded of ghoRegCheck2 to bState Set Checked_State of oRegistryChangesNeeded to bState Get pbServicePackUpdateNeeded of ghoRegCheck2 to bState Set Checked_State of oServicePackUpdateNeeded to bState End_Procedure Procedure Activating Returns Integer Integer iRetVal Forward Get msg_activating to iRetval If (iRetval=0) Begin Send RetrieveOSInfo Send DoFillList of oList End Procedure_Return iRetval End_Procedure Object oRunChangeProgram_btn is a Button Set Size to 14 74 Set Location to 289 74 Set Label to "Run Change Program" Set psToolTip to "Runs the change program that performs registry changes. It is only necessary to do so if the 'Registry Changes Needed' checkbox is checked and has a RED background." Set peAnchors to anNone Procedure OnClick String sPath sProgram Move CS_RegChangeProgram to sProgram Get psProgramPath of (phoWorkspace(ghoApplication)) to sPath Get PathAtIndex of (phoWorkspace(ghoApplication)) sPath 1 to sPath Runprogram Background sProgram sPath End_Procedure End_Object Object oRunWindowsUpdate_btn is a Button Set Size to 14 74 Set Location to 289 169 Set Label to "Run Windows Update" Set psToolTip to "Run Windows Update. It is only necessary to do so if the 'Service Pack Update Needed' checkbox is checked and has a RED background." Set peAnchors to anNone Procedure OnClick Runprogram Background CS_WindowsUpdate End_Procedure End_Object Object oInfo_tb is a TextBox Set Auto_Size_State to False Set Size to 22 456 Set Location to 14 11 Set Label to ("NOTE: This is just info about the current machine's settings. You can NOT make changes here. Do that in the ghoRegCheck2 object - or click the '" + Label(oRunChangeProgram_btn) + "' button if registry changes are needed. Hover the mouse over an item to read the tooltip text.") Set Justification_Mode to JMode_Left End_Object End_Object