Sign in to follow this  
Followers 0
dbecker

I really hope that there is a simple solution to this that I'm not seeing

5 posts in this topic

okay, I know this is a lot of code, but I"ve got a problem that I'm trying to work.

the first section of the code declares an array, $diagnose, that searches the registry and some directories on the hard drive, in the form of If NOT regread, and If NOT File Exists. I then have the array displayed in the form of a variable ($List = $List & $diagnose) in an edit box on the first of three tabs. Below said tab, is a button labeled Re-Scan, which, I need to carry out the scan again(and multiple times over if necessary)and display the new results in the edit box, assuming that something has changed since the initial scan. This is where the problem lies. I can't get it to display anything new. Anyone have any suggestions?

#include <GUIConstants.au3>
#include <Array.au3>
Global $diagnose[28]
Global $n = 1
ProgressOn ("Now Diagnosing...","Please wait for the scan to finish")
If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB873333", "Installed") then
$diagnose[$n] = "Windows Update KB873333"
$n = $n + 1
EndIf
Sleep (150)
ProgressSet (4)
If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB885250", "Installed") then 
$diagnose[$n] = "Windows Update KB885250"
$n = $n + 1
EndIf
Sleep (150)
ProgressSet (8)
If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB886185", "Installed") then 
$diagnose[$n] = "Windows Update KB886185"
$n = $n + 1
EndIf
Sleep (150)
ProgressSet (12)
If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB888113", "Installed") then 
$diagnose[$n] = "Windows Update KB888113"
$n = $n + 1
EndIf
Sleep (150)
ProgressSet (16) 
If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB891781", "Installed") then 
$diagnose[$n] = "Windows Update KB891781"
$n = $n + 1
EndIf
Sleep (150)
ProgressSet (20)
If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB893066", "Installed") then 
$diagnose[$n] = "Windows Update KB893066"
$n = $n + 1
EndIf
Sleep (150)
ProgressSet (24)
If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB896358", "Installed") then 
$diagnose[$n] = "Windows Update KB896358"
$n = $n + 1
EndIf
Sleep (150)
ProgressSet (28)
If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB896422", "Installed") then 
$diagnose[$n] = "Windows Update KB896422"
$n = $n + 1
EndIf
Sleep (150)
ProgressSet (32)
If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB896423", "Installed") then 
$diagnose[$n] = "Windows Update KB896423"
$n = $n + 1
EndIf
Sleep (150)
ProgressSet (36)
If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB896424", "Installed") then 
$diagnose[$n] = "Windows Update KB896424"
$n = $n + 1
EndIf
Sleep (150)
ProgressSet (40)
If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB896688", "Installed") then 
$diagnose[$n] = "Windows Update KB896688"
$n = $n + 1
EndIf
Sleep (150)
ProgressSet (43)
If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB896727", "Installed") then 
$diagnose[$n] = "Windows Update KB896727"
$n = $n + 1
EndIf
Sleep (150)
ProgressSet (45)
If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB899588", "Installed") then 
$diagnose[$n] = "Windows Update KB899588"
$n = $n + 1
EndIf
Sleep (150)
ProgressSet (47)
If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB899589", "Installed") then 
$diagnose[$n] = "Windows Update KB899589"
$n = $n + 1
EndIf
Sleep (150)
ProgressSet (50)
If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB900725", "Installed") then 
$diagnose[$n] = "Windows Update KB900725"
$n = $n + 1
EndIf
Sleep (150)
ProgressSet (54)
If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB901017", "Installed") then 
$diagnose[$n] = "Windows Update KB901017"
$n = $n + 1
EndIf
Sleep (150)
ProgressSet (57)
If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB901214", "Installed") then 
$diagnose[$n] = "Windows Update KB901214"
$n = $n + 1
EndIf
Sleep (150)
ProgressSet (61)
If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB902400", "Installed") then 
$diagnose[$n] = "Windows Update KB902400"
$n = $n + 1
EndIf
Sleep (150)
ProgressSet (64)
If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB904706", "Installed") then 
$diagnose[$n] = "Windows Update KB904706"
$n = $n + 1
EndIf
Sleep (150)
ProgressSet (68)
If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB905414", "Installed") then 
$diagnose[$n] = "Windows Update KB905414"
$n = $n + 1
EndIf
Sleep (150)
ProgressSet (71)
If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB905749", "Installed") then 
$diagnose[$n] = "Windows Update KB905749"
$n = $n + 1
EndIf
Sleep (150)
ProgressSet (75)
If NOT FileExists ("C:\Program Files\Microsoft AntiSpyware\GIANTAntiSpywareMain.exe") Then 
$diagnose[$n] = "Microsoft Anti-SpyWare"
$n = $n + 1
EndIf
Sleep (150)
ProgressSet (78)
If NOT FileExists ("C:\Program Files\Symantec AntiVirus\VPTray.exe") then 
$diagnose[$n] = "Norton Anti-Virus"
$n = $n + 1
EndIf
Sleep (150)
ProgressSet (82)
If NOT FileExists ("C:\Program Files\Cisco Systems\Clean Access Agent\CCAAgent.exe") then 
$diagnose[$n] = "Cisco Clean Access Agent"
$n = $n + 1
EndIf
Sleep (150)
ProgressSet (86)
If NOT FileExists ("C:\Program Files\Mozilla Firefox\firefox.exe") Then 
$diagnose[1] = "Mozilla Firefox"
$n = $n + 1
EndIf
Sleep (150)
ProgressSet (89)
If NOT FileExists ("C:\Program Files\Spybot - Search & Destroy\SpybotSD.exe") Then 
$diagnose[$n] = "Spy-Bot Search and Destroy"
$n = $n + 1
EndIf
Sleep (150)
ProgressSet (93)
If NOT FileExists ("C:\Program Files\Lavasoft\Ad-Aware SE Personal\Ad-Aware.exe") Then 
$diagnose[$n] = "Ad-Aware SE Personal"
$n = $n + 1
EndIf
Sleep (150)
ProgressSet (96)
If NOT FileExists ("C:\WINDOWS\system32\xpsp2res.dll") Then 
$diagnose[$n] = "WindowsXP Service Pack2"
$n = $n + 1
EndIf
ProgressSet (100)
ProgressOff()


DirCreate ("C:\Ubertor Patch")
GUICreate("The RezNet Setup Application",640,480) ; will create a dialog box that when displayed is centered
FileInstall ("C:\Documents and Settings\David Becker\My Documents\Work\Ubertor Patch\imtlogo.jpg", "C:\WINDOWS\system32\oobe\images\imtlogo.jpg")
FileInstall ("C:\Documents and Settings\David Becker\My Documents\Work\Ubertor Patch\HelpFile.html", "C:\Ubertor Patch\HelpFile.html")
FileInstall ("C:\Documents and Settings\David Becker\My Documents\Work\Ubertor Patch\Updating_Symantec_Antivirus.html", "C:\Ubertor Patch\Updating_Symantec_Antivirus.html")
FileInstall ("C:\Documents and Settings\David Becker\My Documents\Work\Ubertor Patch\imtsslogo.jpg", "C:\Ubertor Patch\imtsslogo.jpg")
FileInstall ("C:\Documents and Settings\David Becker\My Documents\Work\Ubertor Patch\start.jpg", "C:\Ubertor Patch\start.jpg")
FileInstall ("C:\Documents and Settings\David Becker\My Documents\Work\Ubertor Patch\end.jpg", "C:\Ubertor Patch\end.jpg")
FileInstall ("C:\Documents and Settings\David Becker\My Documents\Work\Ubertor Patch\finish.jpg", "C:\Ubertor Patch\finish.jpg")
FileInstall ("C:\Documents and Settings\David Becker\My Documents\Work\Ubertor Patch\LiveUpdate.jpg", "C:\Ubertor Patch\LiveUpdate.jpg")
FileInstall ("C:\Documents and Settings\David Becker\My Documents\Work\Ubertor Patch\main.jpg", "C:\Ubertor Patch\main.jpg")
FileInstall ("C:\Documents and Settings\David Becker\My Documents\Work\Ubertor Patch\tray.jpg", "C:\Ubertor Patch\tray.jpg")
FileInstall ("C:\Documents and Settings\David Becker\My Documents\Work\Ubertor Patch\updating.jpg", "C:\Ubertor Patch\updating.jpg")
FileInstall ("C:\Documents and Settings\David Becker\My Documents\Work\Ubertor Patch\windows.jpg", "C:\WINDOWS\system32\oobe\images\windows.jpg")
FileInstall ("C:\Documents and Settings\David Becker\My Documents\Work\Ubertor Patch\symantec.bmp", "C:\WINDOWS\system32\oobe\images\symantec.bmp")
FileInstall ("C:\Documents and Settings\David Becker\My Documents\Work\Ubertor Patch\firefox.jpg", "C:\WINDOWS\system32\oobe\images\firefox.jpg")
FileInstall ("C:\Documents and Settings\David Becker\My Documents\Work\Ubertor Patch\ccaa.jpg", "C:\WINDOWS\system32\oobe\images\ccaa.jpg")
FileInstall ("C:\Documents and Settings\David Becker\My Documents\Work\Ubertor Patch\sbsdlogo.bmp", "C:\WINDOWS\system32\oobe\images\sbsdlogo.bmp")
FileInstall ("C:\Documents and Settings\David Becker\My Documents\Work\Ubertor Patch\adobereader.bmp", "C:\WINDOWS\system32\oobe\images\adobereader.bmp")
FileInstall ("C:\Documents and Settings\David Becker\My Documents\Work\Ubertor Patch\trillian.jpg", "C:\WINDOWS\system32\oobe\images\trillian.jpg")
FileInstall ("C:\Documents and Settings\David Becker\My Documents\Work\Ubertor Patch\msasw.jpg", "C:\WINDOWS\system32\oobe\images\msasw.jpg")
FileInstall ("C:\Documents and Settings\David Becker\My Documents\Work\Ubertor Patch\adaware.bmp", "C:\WINDOWS\system32\oobe\images\adaware.bmp")
FileInstall ("C:\Documents and Settings\David Becker\My Documents\Work\Ubertor Patch\apulogoteal.jpg", "C:\Windows\system32\oobe\images\apulogoteal.jpg")
FileInstall ("C:\Documents and Settings\David Becker\My Documents\Work\Ubertor Patch\blackbar.jpg", "C:\Windows\system32\oobe\images\blackbar.jpg")


GUISetFont(9, 300)
GUISetBkColor(0x415A57)
$tab=GUICtrlCreateTab (0,0,640,25)
GUICtrlSetColor (-1, 0xB1B1AD)
$tab0=GUICtrlCreateTabitem ("              Scan Results             ")
$tab0=GUICtrlCreatePic(@Systemdir & "\oobe\images\imtlogo.jpg",0,26,320,237)
$tab0=GUICtrlCreatePic(@Systemdir & "\oobe\images\apulogoteal.jpg",518,385,122,78)
$tab0=GUICtrlCreateLabel ("The programs and updates that you need are listed below.",0,262,320,20)
GUICtrlSetColor (-1, 0xB1B1AD)

Local $List = ''
For $I = 1 To $N - 1
    $List = $List & $Diagnose[$I] & @CRLF
Next
$Font = "Times New Roman Bold"
$Tab0Edit = GUICtrlCreateEdit($List,0,280,320,155, $ES_AUTOVSCROLL + $WS_VSCROLL + $WS_EX_TRANSPARENT)
GUICtrlSetColor (-1, 0xB1B1AD)
$tab0Edit = GUICtrlSetFont(-1,10,350,0,$Font)
GUISetBkColor (-1, 0x415A57)
GUICtrlSetColor (-1, 0xB1B1AD)
$tab0ReScan=GUICtrlCreateButton ("Re-Scan",0,436,320,25)
GUICtrlSetColor (-1, 0xB1B1AD)
$tab0InstructionsLabel=GUICtrlCreateLabel ("Instructions:",321,26,320,20)
GUICtrlSetColor (-1, 0xB1B1AD)
GUICtrlSetFont ($tab0InstructionsLabel,15,450,0,$Font)
$tab0InfoLabel=GUICtrlCreateLabel ("This program gives you everything that you need to access the student networks here on campus. First, look at the list below, and install any required updates and programs. The items that you must have are on the 'Required Updates and Programs' tab, while other items, that are important and/or useful, but not required, are on the 'Optional Programs' tab. If you have any questions, please reference the Help File. If you require additional assistance, contact the Support Desk, as listed below..",320,48,320,450)
GUICtrlSetColor (-1, 0xB1B1AD)
GUICtrlSetFont ($tab0InfoLabel,11,150,0,$Font)
GUISetBkColor (-1, 0x415A57)
$tab0SupportLabel=GUICtrlCreateLabel ("IMT Support Desk",320,308,320,20)
GUICtrlSetColor (-1, 0xB1B1AD)
$tab0PhoneLabel=GUICtrlCreateLabel("Phone: (626)815-5050",320,328,320,20)
GUICtrlSetColor (-1, 0xB1B1AD)
$tab0EmailLabel=GUICtrlCreateLabel("Email: support@apu.edu",320,348,320,20) 
GUICtrlSetColor (-1, 0xB1B1AD)
$tab0MonLabel=GUICtrlCreateLabel ("Mon - Thur 7:00 AM to 10:00 PM",320,368,320,20) 
GUICtrlSetColor (-1, 0xB1B1AD)
$tab0FriLabel=GUICtrlCreateLabel ("Fri 8:00 AM to 5:00 PM",320,388,320,20)
GUICtrlSetColor (-1, 0xB1B1AD)
$tab0SatLabel=GUICtrlCreateLabel ("Sat 12:00 PM to 6:00 PM",320,408,320,20)
GUICtrlSetColor (-1, 0xB1B1AD)
$tab0SunLabel=GUICtrlCreatelabel ("Sun 2:00 PM to 8:00 PM",320,428,320,20)
GUICtrlSetColor (-1, 0xB1B1AD)
GUICtrlSetFont ($tab0SupportLabel,14,400,0,$Font)
GUICtrlSetFont ($tab0PhoneLabel,14,400,0,$Font)
GUICtrlSetFont ($tab0EmailLabel,14,400,0,$Font)
GUICtrlSetFont ($tab0MonLabel,14,400,0,$Font)
GUICtrlSetFont ($tab0FriLabel,14,400,0,$Font)
GUICtrlSetFont ($tab0SatLabel,14,400,0,$Font)
GUICtrlSetFont ($tab0SunLabel,14,400,0,$Font)

$tab1=GUICtrlCreateTabitem ("          Required Updates and Programs            ")
$tab1=GUICtrlCreatePic(@Systemdir & "\oobe\images\imtlogo.jpg",0,26,320,237)
$tab1Edit = GUICtrlCreateEdit("",0,263,320,220,$ES_MULTILINE + $ES_AUTOVSCROLL + $WS_EX_TRANSPARENT)
GUISetBkColor (-1, 0x415A57)
GUICtrlSetColor (-1, 0xB1B1AD)

$tab1XPPatchLabel=GUICtrlCreateLabel ("1. Windows Updates",400,26,240,20,$SS_CENTER)
GUICtrlSetColor (-1, 0xB1B1AD)
GUICtrlSetFont ($tab1XPPatchLabel,10,400,0,$Font)
GUICtrlSetColor (-1, 0xB1B1AD)
$tab1=GUICtrlCreatePic(@Systemdir & "\oobe\images\windows.jpg",324,96,70,60)
$tab1XPPatch=GUICtrlCreateButton ("Install",400,51,240,30)
$tab1XPPatchInfo=GUICtrlCreateButton ("Information",400,81,240,30)

$tab1SP2Label=GUICtrlCreateLabel ("2. Windows XP Service Pack 2",400,126,240,20,$SS_CENTER)
GUICtrlSetColor (-1, 0xB1B1AD)
GUICtrlSetFont ($tab1SP2Label,10,400,0,$Font)
GUICtrlSetColor (-1, 0xB1B1AD)
$tab1SP2=GUICtrlCreateButton ("Install",400,146,240,30)
$tab1SP2Info=GUICtrlCreateButton ("Information",400,176,240,30)

$tab1CCAALabel=GUICtrlCreatelabel ("3. Cisco Clean Access Agent",400,221,240,20,$SS_CENTER)
GUICtrlSetColor (-1, 0xB1B1AD)
GUICtrlSetFont ($tab1CCAALabel,10,400,0,$Font)
GUICtrlSetColor (-1, 0xB1B1AD)
$tab1=GUICtrlCreatePic(@Systemdir & "\oobe\images\ccaa.jpg",323,221,75,60)
$tab1CCAA=GUICtrlCreateButton ("Install",400,241,240,30)
$tab1CCAAInfo=GUICtrlCreateButton ("Information",400,271,240,30)

$tab1NortonLabel=GUICtrlCreateLabel ("4. Norton AntiVirus",400,316,240,20,$SS_CENTER)
GUICtrlSetColor (-1, 0xB1B1AD)
GUICtrlSetFont ($tab1NortonLabel,10,400,0,$Font)
GUICtrlSetColor (-1, 0xB1B1AD)
$tab1=GUICtrlCreatePic(@Systemdir & "\oobe\images\symantec.bmp",336,337,49,46)
$tab1Norton=GUICtrlCreateButton ("Install",400,336,240,30)
$tab1NortonInfo=GUICtrlCreateButton ("Information",400,366,240,30)

$tab1NortonUpdateLabel=GUICtrlCreateLabel ("5. Norton Virus Definitions",400,411,240,25,$SS_CENTER)
GUICtrlSetColor (-1, 0xB1B1AD)
GUICtrlSetFont ($tab1NortonUpdateLabel,10,400,0,$Font)
GUICtrlSetColor (-1, 0xB1B1AD)
$tab1NortonUpdatesInfo=GUICtrlCreateButton ("Information",400,432,240,30)


;tab2 creation
$tab2=GUICtrlCreateTabItem ("           Optional Programs            ")
$tab2=GUICtrlCreatePic(@Systemdir & "\oobe\images\imtlogo.jpg",0,26,320,237)
$tab2Edit = GUICtrlCreateEdit("",0,263,320,220,$ES_MULTILINE + $ES_AUTOVSCROLL + $WS_EX_TRANSPARENT)
GUISetBkColor (-1, 0x415A57)
GUICtrlSetColor (-1, 0xB1B1AD)

$tab2MicrosoftASWLabel=GUICtrlCreateLabel ("1. Install Microsoft AntiSpyWare",400,26,240,20,$SS_CENTER)
GUICtrlSetColor (-1, 0xB1B1AD)
GUICtrlSetFont ($tab2MicrosoftASWLabel,10,400,0,$Font)
GUICtrlSetColor (-1, 0xB1B1AD)
$tab2=GUICtrlCreatePic(@Systemdir & "\oobe\images\msasw.jpg",324,29,70,65)
$tab2MicrosoftASW=GUICtrlCreateButton ("Install",400,46,240,27)
$tab2MicrosoftASWInfo=GUICtrlCreateButton ("Information",400,73,240,27)

$tab2AdAwareLabel=GUICtrlCreateLabel ("2. Install Ad-Aware SE Personal",400,100,240,20,$SS_CENTER)
GUICtrlSetColor (-1, 0xB1B1AD)
GUICtrlSetFont ($tab2AdAwareLabel,10,400,0,$Font)
GUICtrlSetColor (-1, 0xB1B1AD)
$tab2=GUICtrlCreatePic(@Systemdir & "\oobe\images\adaware.bmp",334,113,50,50)
$tab2AdAware=GUICtrlCreateButton ("Install",400,117,240,27)
$tab2AdAwareInfo=GUICtrlCreateButton ("Information",400,143,240,27)

$tab2SpyBotLabel=GUICtrlCreatelabel ("3. Install SpyBot Search and Destroy",400,176,240,20,$SS_CENTER)
GUICtrlSetColor (-1, 0xB1B1AD)
GUICtrlSetFont ($tab2SpyBotLabel,10,400,0,$Font)
GUICtrlSetColor (-1, 0xB1B1AD)
$tab2=GUICtrlCreatePic(@Systemdir & "\oobe\images\sbsdlogo.bmp",321,192,79,30)
$tab2SpyBot=GUICtrlCreateButton ("Install",400,191,240,27)
$tab2SpyBotInfo=GUICtrlCreateButton ("Information",400,218,240,27)

$tab2FireFoxLabel=GUICtrlCreateLabel ("4. Install Mozilla Firefox",400,249,240,20,$SS_CENTER)
GUICtrlSetColor (-1, 0xB1B1AD)
GUICtrlSetFont ($tab2FireFoxLabel,10,400,0,$Font)
GUICtrlSetColor (-1, 0xB1B1AD)
$tab2=GUICtrlCreatePic(@Systemdir & "\oobe\images\firefox.jpg",331,255,60,60)
$tab2Firefox=GUICtrlCreateButton ("Install",400,264,240,27)
$tab2FirefoxInfo=GUICtrlCreateButton ("Information",400,291,240,27)

$tab2TrillianLabel=GUICtrlCreateLabel ("5. Install Trillian Instant Messenger",400,320,240,25,$SS_CENTER)
GUICtrlSetColor (-1, 0xB1B1AD)
GUICtrlSetFont ($tab2TrillianLabel,10,400,0,$Font)
GUICtrlSetColor (-1, 0xB1B1AD)
$tab2=GUICtrlCreatePic(@Systemdir & "\oobe\images\trillian.jpg",321,320,78,68)
$tab2Trillian=GUICtrlCreateButton ("Install",400,334,240,27)
$tab2TrillianInfo=GUICtrlCreateButton ("Information",400,359,240,27)

$tab2AcrobatLabel=GUICtrlCreateLabel ("6. Install Adobe Acrobat Reader",400,393,240,20,$SS_CENTER)
GUICtrlSetColor (-1, 0xB1B1AD)
GUICtrlSetFont ($tab2AcrobatLabel,10,400,0,$Font)
GUICtrlSetColor (-1, 0xB1B1AD)
$tab2=GUICtrlCreatePic(@Systemdir & "\oobe\images\adobereader.bmp",326,398,70,62)
$tab2Acrobat=GUICtrlCreateButton ("Install",400,407,240,27)
$tab2AcrobatInfo=GUICtrlCreateButton ("Information",400,430,240,27)

GUICtrlCreateTabitem ("")  ; end tabitem definition

$filemenu = GUICtrlCreateMenu ("&File",-1,1)

$helpmenu = GUICtrlCreateMenu ("&Help")

$helpitem = GUICtrlCreateMenuitem ("Help",$helpmenu)
$exititem = GUICtrlCreateMenuitem ("Exit",$filemenu)
$abootitem = GUICtrlCreateMenuitem ("Aboot",$helpmenu)

GUISetState ()
;$drive=DriveGetLabel (@WorkingDir)
Do
  $msg = GUIGetMsg ()

   Select
      Case $msg = $tab1XPPatch
     Run (@ScriptDir & "\Ubertor Patch\XPPatch Installer.exe")
      Case $msg = $tab1Norton
         Run (@ScriptDir & "\Ubertor Patch\Norton 10 Installer2.exe")
      Case $msg = $tab2MicrosoftASW
     Run (@ScriptDir & "\Ubertor Patch\MicrosoftASW AutoInstaller.exe")
      Case $msg = $tab2AdAware
     Run (@ScriptDir & "Ubertor Patch\aawsepersonal.exe")
      Case $msg = $tab1CCAA
     Run (@ScriptDir & "Ubertor Patch\CCAAgent_Setup.exe")
      Case $msg = $tab2Firefox
     Run (@ScriptDir & "Ubertor Patch\Firefox Setup.exe")
      Case $msg = $tab2Acrobat
     Run (@ScriptDir & "Ubertor Patch\AcrobatSetup.exe")
      Case $msg = $tab2Trillian
     Run (@ScriptDir & "Ubertor Patch\Trillian.exe")
      Case $msg = $tab2SpyBot
     Run (@ScriptDir & "Ubertor Patch\spybotsd14.exe")
      Case $msg = $tab1SP2
     Run (@ScriptDir & "Ubertor Patch\WindowsXP-KB835935.exe")
      Case $msg = $tab1XPPatchInfo
         GUICtrlSetData ($tab1Edit, "This program will install all of the post-Service Pack 2 updates that are required to access the network." & Chr (52))
      Case $msg = $tab1SP2Info
         GUICtrlSetData ($tab1Edit, "This is a very large package of updates and hotfixes for Windows XP. Most 'factory fresh' computers now come with it pre-installed, but if the 'Scan Results' tab indicates that you require it, please install it before proceeding to other Windows updates. Be aware that this installation will usually take between 30 minuntes and 2 hours, and will require  you to restart your computer once it is finished.")
      Case $msg = $tab1NortonInfo
         GUICtrlSetData ($tab1Edit, "This is APU's corporate edition of Norton Anti-Virus. This version has a four-year subscription with it to Live-Update for up-to-date virus definitions. Please un-install other versions of Norton, as well as other anti-virus programs before installing.")
      Case $msg = $tab1CCAAInfo
         GUICtrlSetData ($tab1Edit, "This program is required for authentication on the network. You must use this to ensure that the network is safe and secure.")
      Case $msg = $tab1NortonUpdatesInfo
         $url = "C:\Ubertor Patch\Updating_Symantec_Antivirus.html"
     Run("C:\Program Files\Internet Explorer\iexplore.exe " & $url)
      Case $msg = $tab2MicrosoftASWInfo
         GUICtrlSetData ($tab2Edit, "This program is a popular, effective anti-spyware program. While not required for the network, it is still a wise program to have on hand for regular use.")
      Case $msg = $tab2AdAwareInfo
         GUICtrlSetData ($tab2Edit, "This program is another popular, effective anti-spyware program.")
      Case $msg = $tab2FirefoxInfo
         GUICtrlSetData ($tab2Edit, "This program is a web browser that is a very widely acceptable alternative to using Internet Explorer. Please note that it is not a requirement, nor is it supported by APU yet.")
      Case $msg = $tab2TrillianInfo
         GUICtrlSetData ($tab2Edit, "This program is a popular alternative to using AIM, MSN, and Yahoo! instant messenger programs. Also not a requirement.")
      Case $msg = $tab2AcrobatInfo
         GUICtrlSetData ($tab2Edit, "This program is used to open .PDF files. You will not be able to open these file types without Acrobat Reader.")
      Case $msg = $tab2SpyBotInfo
         GUICtrlSetData ($tab2Edit, "This program is another popular, effective anti-spyware program.")
      Case $msg = $tab0ReScan
    MsgBox (0, "",$n)
    GUICtrlSetData ($tab0Edit, "")
    Global $diagnose[28]
    Global $n = $n - 2
    ProgressOn ("Now Diagnosing...","Please wait while we scan your computer")
    If NOT RegRead ("HKELOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB873333", "Installed") then
    $diagnose[$n] = "Windows Update KB873333"
    $n = $n + 1
    EndIf
    Sleep (150)
    ProgressSet (4)
    If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB885250", "Installed") then 
    $diagnose[$n] = "Windows Update KB885250"
    $n = $n + 1
    EndIf
    Sleep (150)
    ProgressSet (8)
    If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB886185", "Installed") then 
    $diagnose[$n] = "Windows Update KB886185"
    $n = $n + 1
    EndIf
    Sleep (150)
    ProgressSet (12)
    If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB888113", "Installed") then 
    $diagnose[$n] = "Windows Update KB888113"
    $n = $n + 1
    EndIf
    Sleep (150)
    ProgressSet (16) 
    If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB891781", "Installed") then 
    $diagnose[$n] = "Windows Update KB891781"
    $n = $n + 1
    EndIf
    Sleep (150)
    ProgressSet (20)
    If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB893066", "Installed") then 
    $diagnose[$n] = "Windows Update KB893066"
    $n = $n + 1
    EndIf
    Sleep (150)
    ProgressSet (24)
    If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB896358", "Installed") then 
    $diagnose[$n] = "Windows Update KB896358"
    $n = $n + 1
    EndIf
    Sleep (150)
    ProgressSet (28)
    If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB896422", "Installed") then 
    $diagnose[$n] = "Windows Update KB896422"
    $n = $n + 1
    EndIf
    Sleep (150)
    ProgressSet (32)
    If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB896423", "Installed") then 
    $diagnose[$n] = "Windows Update KB896423"
    $n = $n + 1
    EndIf
    Sleep (150)
    ProgressSet (36)
    If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB896424", "Installed") then 
    $diagnose[$n] = "Windows Update KB896424"
    $n = $n + 1
    EndIf
    Sleep (150)
    ProgressSet (40)
    If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB896688", "Installed") then 
    $diagnose[$n] = "Windows Update KB896688"
    $n = $n + 1
    EndIf
    Sleep (150)
    ProgressSet (43)
    If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB896727", "Installed") then 
    $diagnose[$n] = "Windows Update KB896727"
    $n = $n + 1
    EndIf
    Sleep (150)
    ProgressSet (45)
    If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB899588", "Installed") then 
    $diagnose[$n] = "Windows Update KB899588"
    $n = $n + 1
    EndIf
    Sleep (150)
    ProgressSet (47)
    If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB899589", "Installed") then 
    $diagnose[$n] = "Windows Update KB899589"
    $n = $n + 1
    EndIf
    Sleep (150)
    ProgressSet (50)
    If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB900725", "Installed") then 
    $diagnose[$n] = "Windows Update KB900725"
    $n = $n + 1
    EndIf
    Sleep (150)
    ProgressSet (54)
    If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB901017", "Installed") then 
    $diagnose[$n] = "Windows Update KB901017"
    $n = $n + 1
    EndIf
    Sleep (150)
    ProgressSet (57)
    If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB901214", "Installed") then 
    $diagnose[$n] = "Windows Update KB901214"
    $n = $n + 1
    EndIf
    Sleep (150)
    ProgressSet (61)
    If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB902400", "Installed") then 
    $diagnose[$n] = "Windows Update KB902400"
    $n = $n + 1
    EndIf
    Sleep (150)
    ProgressSet (64)
    If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB904706", "Installed") then 
    $diagnose[$n] = "Windows Update KB904706"
    $n = $n + 1
    EndIf
    Sleep (150)
    ProgressSet (68)
    If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB905414", "Installed") then 
    $diagnose[$n] = "Windows Update KB905414"
    $n = $n + 1
    EndIf
    Sleep (150)
    ProgressSet (71)
    If NOT RegRead ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\KB905749", "Installed") then 
    $diagnose[$n] = "Windows Update KB905749"
    $n = $n + 1
    EndIf
    Sleep (150)
    ProgressSet (75)
    If NOT FileExists ("C:\Program Files\Microsoft AntiSpyware\GIANTAntiSpywareMain.exe") Then  
    $diagnose[$n] = "Microsoft Anti-SpyWare"
    $n = $n + 1
    EndIf
    Sleep (150)
    ProgressSet (78)
    If NOT FileExists ("C:\Program Files\Symantec AntiVirus\VPTray.exe") then 
    $diagnose[$n] = "Norton Anti-Virus"
    $n = $n + 1
    EndIf
    Sleep (150)
    ProgressSet (82)
    If NOT FileExists ("C:\Program Files\Cisco Systems\Clean Access Agent\CCAAgent.exe") then 
    $diagnose[$n] = "Cisco Clean Access Agent"
    $n = $n + 1
    EndIf
    Sleep (150)
    ProgressSet (86)
    If NOT FileExists ("C:\Program Files\Mozilla Firefox\firefox.exe") Then 
    $diagnose[$n] = "Mozilla Firefox"
    $n = $n + 1
    EndIf
    Sleep (150)
    ProgressSet (89)
    If NOT FileExists ("C:\Program Files\Spybot - Search & Destroy\SpybotSD.exe") Then 
    $diagnose[$n] = "Spy-Bot Search and Destroy"
    $n = $n + 1
    EndIf
    Sleep (150)
    ProgressSet (93)
    If NOT FileExists ("C:\Program Files\Lavasoft\Ad-Aware SE Personal\Ad-Aware.exe") Then 
    $diagnose[$n] = "Ad-Aware SE Personal"
    $n = $n + 1
    EndIf
    Sleep (150)
    ProgressSet (96)
    If NOT FileExists ("C:\WINDOWS\system32\xpsp2res.dll") Then 
    $diagnose[$n] = "WindowsXP Service Pack2"
    $n = $n + 1
    EndIf
    ProgressSet (100)
    ProgressOff()
    Local $List = ''
    For $i = 1 To $n - 1
       $List = $List & $diagnose[$i] & @CRLF
    Next
    GUICtrlSetData ($tab0edit, $List)
   EndSelect
      If $msg = $GUI_EVENT_CLOSE Or $msg = $exititem Then
          FileRecycle ("C:\Ubertor Patch")
          Exitloop
      EndIf
      If $msg = $helpitem Then 
              $url = "C:\Ubertor Patch\HelpFile.html"
        Run("c:\program files\internet explorer\iexplore.exe " & $url)
      EndIf
      If $msg = $abootitem Then MsgBox (0, "Aboot", "RezNet Setup Application Student V3.0. ")
Until $msg = $GUI_EVENT_CLOSE

I hope someone has an idea of how to fix this monstrosity


"I wish I could say something that was classy and inspirational, but that just wouldn't be our style. Pain heals. Chicks dig scars. Glory lasts forever." - Shane Falco, The Replacements

Share this post


Link to post
Share on other sites



okay, I know this is a lot of code, but I"ve got a problem that I'm trying to work.

the first section of the code declares an array, $diagnose, that searches the registry and some directories on the hard drive, in the form of If NOT regread, and If NOT File Exists. I then have the array displayed in the form of a variable ($List = $List & $diagnose) in an edit box on the first of three tabs. Below said tab, is a button labeled Re-Scan, which, I need to carry out the scan again(and multiple times over if necessary)and display the new results in the edit box, assuming that something has changed since the initial scan. This is where the problem lies. I can't get it to display anything new. Anyone have any suggestions?

a little too much code to look through for me right now. I ran into a similar issue at work with a script that i made to consolidate the data from multiple real time reports. I had names that needed to be addressed listed in a listview, and wanted to make a clean refresh. The right way to do it, i believe, is to have all of your data gathering done by a function that can be called with the button, then just add the stuff that's not already there. I can't remember what kind of issues i had trying to do it that way, but for whatever reason i ended up making my refresh button pretty much restart the program. it checks what check boxes are selected (lots of optional functionality in my script) and then hide the gui, run itself, then recheck the appropriate boxes once the new instance of the gui pops up (with updated info), and finally exit itself once the new data has been updated. It's not a very elegant solution by any stretch of the imagination, but it saved me the time of duplicating code, or trying to change the original code to fit the new idea... I'm trying to get permission to come on these forums at work, so if i'm able to tomorrow, i'll post my code up here so you can see what i mean if you want.


1100111 00001011101111 00011101101111 00010111100100 00001111110100 00110111110010 00101101111001 0011100i didn't make up this form of encryption, but i like it.credit to the lvl 6 challenge on arcanum.co.nz

Share this post


Link to post
Share on other sites

I hope someone has an idea of how to fix this monstrosity

Definitely using functions will make this monstrosity easier to debug. You do not know how to use functions, do you ? else this is what you should be doing.

This may help you on the idea of cleaning up your code.

_HotfixDetect( 4, "KB873333")
_HotfixDetect( 8, "KB885250")
_HotfixDetect(12, "KB886185")
_HotfixDetect(16, "KB888113")
...
...

Func _HotfixDetect($progress, $hotfix_number)
    If NOT RegRead ("HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\HotFix\" & $hotfix_number, "Installed") then
        $diagnose[$n] = "Windows Update " & $hotfix_number
        $n = $n + 1
    EndIf
    Sleep(150)
    ProgressSet ($progress)
EndFunc

This starts to cleanup the first part of the Hotfixes section that are repeatly have the same lines of code. Once cleaned up, the bug will more easily be seen.

Share this post


Link to post
Share on other sites

replace all of these:

GUISetBkColor (-1, 0x415A57)

with these:

GUISetBkColor (0x415A57)

...by the way, it's pronounced: "JIF"... Bob Berry --- inventor of the GIF format

Share this post


Link to post
Share on other sites

hey thanks for the help, I found the problem, my scripts were fine, but for some reason having an alternate font type/size in the edit box prevented it from being changed.. weird.. but, everything works fine now. thanks for the suggestions!


"I wish I could say something that was classy and inspirational, but that just wouldn't be our style. Pain heals. Chicks dig scars. Glory lasts forever." - Shane Falco, The Replacements

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0