Tripredacus Posted December 15, 2008 Posted December 15, 2008 Greetings, I am currently trying to make GUIs again with AutoIT. I had previously made one with radio buttons but that was easy. Now I am having problems with checkboxes or the ability to execute more than one thing at a time. It is for a program selector, you choose which to run, and it runs them for you. All that the menu actually does it copy files. I have not used Case or Switch statements in a long time so I don't remember how to use them properly. My code works fine if there is one checkbox, but when I add the second one, it always pops up the msgbox specified in the elseif statement. While 1 $Msg = GuiGetMsg() Switch $Msg Case $GUI_EVENT_CLOSE Exit Case $button1 if GuiCtrlRead($Checkbox1) = $GUI_CHECKED then RunWait (@ComSpec & " /c md c:\temp\nero8ste2") RunWait (@ComSpec & " /c xcopy v:\software\nero\nero8ste2 c:\temp\nero8ste2 /e" ) RunWait (@ComSpec & " /c xcopy v:\software\installer.exe c:\docume~1\alluse~1\startm~1\programs\startup" ) RunWait (@ComSpec & " /c xcopy v:\software\cleanup.exe c:\pnpdrvrs\net" ) Else MsgBox(0, "error", "Nothing was selected!") EndIf Case $button2 if GuiCtrlRead($Checkbox2) = $GUI_CHECKED Then MsgBox (0, "howdy", "This installs E-Trust") Else MsgBox (0, "error", "Nothing was selected!") EndIf EndSwitch WEnd The GUI itself was made with Koda to make things faster for me. So the above is fine until I put 'case $button2' and the code after it but before EndSwitch. What am I doing wrong? Twitter | MSFN | VGCollect
TheOrignl Posted December 15, 2008 Posted December 15, 2008 Greetings, I am currently trying to make GUIs again with AutoIT. I had previously made one with radio buttons but that was easy. Now I am having problems with checkboxes or the ability to execute more than one thing at a time. It is for a program selector, you choose which to run, and it runs them for you. All that the menu actually does it copy files. I have not used Case or Switch statements in a long time so I don't remember how to use them properly. My code works fine if there is one checkbox, but when I add the second one, it always pops up the msgbox specified in the elseif statement. While 1 $Msg = GuiGetMsg() Switch $Msg Case $GUI_EVENT_CLOSE Exit Case $button1 if GuiCtrlRead($Checkbox1) = $GUI_CHECKED then RunWait (@ComSpec & " /c md c:\temp\nero8ste2") RunWait (@ComSpec & " /c xcopy v:\software\nero\nero8ste2 c:\temp\nero8ste2 /e" ) RunWait (@ComSpec & " /c xcopy v:\software\installer.exe c:\docume~1\alluse~1\startm~1\programs\startup" ) RunWait (@ComSpec & " /c xcopy v:\software\cleanup.exe c:\pnpdrvrs\net" ) Else MsgBox(0, "error", "Nothing was selected!") EndIf Case $button2 if GuiCtrlRead($Checkbox2) = $GUI_CHECKED Then MsgBox (0, "howdy", "This installs E-Trust") Else MsgBox (0, "error", "Nothing was selected!") EndIf EndSwitch WEnd The GUI itself was made with Koda to make things faster for me. So the above is fine until I put 'case $button2' and the code after it but before EndSwitch. What am I doing wrong?What does the code for the GUI look like? There is no ElseIf statement. So I assume you're talking bout the Else statements; if so which Else or are you talking bout both Else cases depending on the button clicked? Managing the complexities of our daily lives is always our own responsibility; Allowing God to help us and accepting His guidance is our choice. The best choice!
enaiman Posted December 15, 2008 Posted December 15, 2008 Sometimes when using GUICtrlRead on a checkbox you might not get accurate results about its state - it is better to use BitAND(GUICtrlRead($Checkbox1), $GUI_CHECKED) instead - this code never failed. While 1 $Msg = GuiGetMsg() Switch $Msg Case $GUI_EVENT_CLOSE Exit Case $button1 if BitAND(GUICtrlRead($Checkbox1), $GUI_CHECKED) then RunWait (@ComSpec & " /c md c:\temp\nero8ste2") RunWait (@ComSpec & " /c xcopy v:\software\nero\nero8ste2 c:\temp\nero8ste2 /e" ) RunWait (@ComSpec & " /c xcopy v:\software\installer.exe c:\docume~1\alluse~1\startm~1\programs\startup" ) RunWait (@ComSpec & " /c xcopy v:\software\cleanup.exe c:\pnpdrvrs\net" ) Else MsgBox(0, "error", "Nothing was selected!") EndIf Case $button2 if BitAND(GUICtrlRead($Checkbox2), $GUI_CHECKED) Then MsgBox (0, "howdy", "This installs E-Trust") Else MsgBox (0, "error", "Nothing was selected!") EndIf EndSwitch WEnd About how to use a certain command? - the "holy" Help file SNMP_UDF ... for SNMPv1 and v2c so far, GetBulk and a new example script wannabe "Unbeatable" Tic-Tac-Toe Paper-Scissor-Rock ... try to beat it anyway :)
Tripredacus Posted January 21, 2009 Author Posted January 21, 2009 Even with this different code, I am constantly getting a pop-up box that says "Nothing was selected". Here is the code for the GUI. #include <GUIConstants.au3> Local $Msg, $button1, $button2, $Checkbox1, $Checkbox2 $Form1 = GUICreate("Form1", 633, 454, 187, 113) $Label1 = GUICtrlCreateLabel("Select a Program to install", 32, 48, 126, 17) $Checkbox1 = GUICtrlCreateCheckbox("Checkbox1", 80, 90, 17, 17) $Label2 = GUICtrlCreateLabel("Nero 8 Essentials Suite 2", 112, 90, 129, 17) $Checkbox2 = GUICtrlCreateCheckbox("Checkbox2", 80, 105, 17, 17) $Label3 = GUICtrlCreateLabel("E-Trust 7.1 OEM", 112, 105, 129, 17) $Button1 = GUICtrlCreateButton("Start", 48, 304, 129, 25, 0) GUISetState() Twitter | MSFN | VGCollect
Moderators Melba23 Posted January 21, 2009 Moderators Posted January 21, 2009 Tripredacus,Try this. I am assuming you only want one thing installed at a time, so I have used radio buttons rather than checkboxes and put them in a group so only one can be selected at any one time. That way you can use an "If...ElseIf...Else" statement to choose what to do:#include <GUIConstants.au3> Local $Msg, $button1, $button2, $Checkbox1, $Checkbox2 $Form1 = GUICreate("Form1", 633, 454, 187, 113) $Label1 = GUICtrlCreateLabel("Select a Program to install", 32, 48, 126, 17) GUICtrlCreateGroup("", 70, 80, 200, 50) $Radio1 = GUICtrlCreateRadio(" Nero 8 Essentials Suite 2", 80, 90, 170, 17) $Radio2 = GUICtrlCreateRadio(" E-Trust 7.1 OEM", 80, 105, 170, 17) GUICtrlCreateGroup("", -99, -99, 1, 1) ;close group $Button1 = GUICtrlCreateButton("Start", 48, 304, 129, 25, 0) GUISetState() While 1 $Msg = GuiGetMsg() Switch $Msg Case $GUI_EVENT_CLOSE Exit Case $button1 if BitAND(GUICtrlRead($Radio1), $GUI_CHECKED) = $GUI_CHECKED then MsgBox (0, "Howdy", "This installs Nero") ElseIf BitAND(GUICtrlRead($Radio2), $GUI_CHECKED) = $GUI_CHECKED Then MsgBox (0, "Howdy", "This installs E-Trust") Else MsgBox (0, "Error", "Nothing was selected!") EndIf EndSwitch WEndYour previous code did not work becasue you had a non-existent $Button2, which always met the criteria for triggering - and of course you had nothing selected to begin with!You will, of course, need to put your install commands in place of the relevant MsgBox statements.Ask if anything is unclear,M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area
Tripredacus Posted January 21, 2009 Author Posted January 21, 2009 OK I see what the issue is. Yes there is no button2. Not sure how I even started this app! No I need to use checkboxes because some instances must copy more than one thing. So if box1 is checked and box2 is checked, do (function) for box1 then do (function) for box2. Basically, if the box is checked, it does that thing, and if it isn't, it doesn't. I can't seem to find any good checkbox examples like this to get a better idea how to do this. Twitter | MSFN | VGCollect
AdmiralAlkex Posted January 21, 2009 Posted January 21, 2009 (edited) Edit: no wait, check what Melba23 posted in post9 instead Edited January 21, 2009 by AdmiralAlkex .Some of my scripts: ShiftER, Codec-Control, Resolution switcher for HTC ShiftSome of my UDFs: SDL UDF, SetDefaultDllDirectories, Converting GDI+ Bitmap/Image to SDL Surface
Tripredacus Posted January 21, 2009 Author Posted January 21, 2009 But Melba23 just told you how to do it 1 post up?? Replace the radios with checkboxes and you are finished.Sorry, brain fart. I used to be real good using this app... fell off the horse I suppose. I'll try this out then. Twitter | MSFN | VGCollect
Moderators Melba23 Posted January 21, 2009 Moderators Posted January 21, 2009 Tripredacus, If you want the option to do both installs at the same time (or rather consecutively!), try this:#include <GUIConstants.au3> Local $Msg, $button1, $button2, $Checkbox1, $Checkbox2 $Form1 = GUICreate("Form1", 633, 454, 187, 113) $Label1 = GUICtrlCreateLabel("Select a Program to install", 32, 48, 126, 17) $Checkbox1 = GUICtrlCreateCheckbox("Checkbox1", 80, 90, 17, 17) $Label2 = GUICtrlCreateLabel("Nero 8 Essentials Suite 2", 112, 90, 129, 17) $Checkbox2 = GUICtrlCreateCheckbox("Checkbox2", 80, 105, 17, 17) $Label3 = GUICtrlCreateLabel("E-Trust 7.1 OEM", 112, 105, 129, 17) $Button1 = GUICtrlCreateButton("Start", 48, 304, 129, 25, 0) GUISetState() While 1 $Msg = GuiGetMsg() Switch $Msg Case $GUI_EVENT_CLOSE Exit Case $button1 $fSelected = False if BitAND(GUICtrlRead($Checkbox1), $GUI_CHECKED) then MsgBox (0, "howdy", "This installs Nero") $fSelected = True EndIf if BitAND(GUICtrlRead($Checkbox2), $GUI_CHECKED) Then MsgBox (0, "howdy", "This installs E-Trust") $fSelected = True EndIf If $fSelected = False Then MsgBox (0, "error", "Nothing was selected!") EndSwitch WEnd Ask again if it is not right - I might try a third time! M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area
Tripredacus Posted January 21, 2009 Author Posted January 21, 2009 I will try this new idea in a minute. I had found an error in my new code and thought that was why it wasn't working. Basically, the last test (I have 4 checkboxes) completed code from only the Nero option and not the other three. Then I realised I forgot to rename some. Here is the new code. expandcollapse popup#include <GUIConstants.au3> Local $Msg, $button1, $Checkbox1, $Checkbox2 $Form1 = GUICreate("Form1", 633, 454, 187, 113) $Label1 = GUICtrlCreateLabel("Select a Program to install", 32, 48, 126, 17) GUICtrlCreateGroup("", 70, 80, 200, 50) $Radio1 = GUICtrlCreateCheckbox(" Nero 8 Essentials Suite 2", 80, 90, 170, 17) $Radio2 = GUICtrlCreateCheckbox(" McAfee 30 Day Trial", 80, 105, 170, 17) $Radio3 = GUICtrlCreateCheckbox(" OfficeReady", 80, 120, 170, 17) $Radio4 = GUICtrlCreateCheckbox(" PowerDVD", 80, 135, 170, 17) GUICtrlCreateGroup("", -99, -99, 1, 1) ;close group $Button1 = GUICtrlCreateButton("Start", 48, 304, 129, 25, 0) GUISetState() While 1 $Msg = GuiGetMsg() Switch $Msg Case $GUI_EVENT_CLOSE Exit Case $button1 RunWait (@ComSpec & " /c xcopy v:\software\installer.exe c:\docume~1\alluse~1\startm~1\programs\startup" ) RunWait (@ComSpec & " /c xcopy v:\software\cleanup.exe c:\pnpdrvrs\net" ) if BitAND(GUICtrlRead($Radio1), $GUI_CHECKED) = $GUI_CHECKED then RunWait (@ComSpec & " /c md c:\temp\nero8ste2") RunWait (@ComSpec & " /c xcopy v:\software\nero\nero8ste2 c:\temp\nero8ste2 /e" ) ElseIf BitAND(GUICtrlRead($Radio2), $GUI_CHECKED) = $GUI_CHECKED Then RunWait (@ComSpec & " /c md c:\temp\mcafee") RunWait (@ComSpec & " /c xcopy v:\software\mcafee\mcafee_30_day_trial c:\temp\mcafee /e" ) ElseIf BitAND(GUICtrlRead($Radio3), $GUI_CHECKED) = $GUI_CHECKED Then RunWait (@ComSpec & " /c md c:\temp\office") RunWait (@ComSpec & " /c xcopy v:\software\microsoft\officeready c:\temp\office /e" ) ElseIf BitAND(GUICtrlRead($Radio4), $GUI_CHECKED) = $GUI_CHECKED Then RunWait (@ComSpec & " /c md c:\temp\powerdvd") RunWait (@ComSpec & " /c xcopy v:\software\powerdvd c:\temp\powerdvd /e" ) Else MsgBox (0, "Error", "Nothing was selected!") EndIf EndSwitch WEnd This is without any changes from "post 9" above. Twitter | MSFN | VGCollect
AdmiralAlkex Posted January 21, 2009 Posted January 21, 2009 Now you only run the first "checked" checkbox, I thought you said you wanted to go through all that were checked?? Take a look at post#9 again and notice that he have one if...then...endif for every checkbox, that's what I think you are after .Some of my scripts: ShiftER, Codec-Control, Resolution switcher for HTC ShiftSome of my UDFs: SDL UDF, SetDefaultDllDirectories, Converting GDI+ Bitmap/Image to SDL Surface
Moderators Melba23 Posted January 21, 2009 Moderators Posted January 21, 2009 Tripredacus, AdmiralAlkex beat me to it. If you want more than 1 thing to happen - you need the Post 9 code. If you want just the first of the checked boxes to run - you need your code at Post 10. If you need just one thing, but the only checked thing, to run - you need the Post 5 code. Hope that is clear! M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area
bartgrefte Posted June 10, 2010 Posted June 10, 2010 Sorry for the kick, but got a question about this script: Tripredacus, If you want the option to do both installs at the same time (or rather consecutively!), try this:#include <GUIConstants.au3> Local $Msg, $button1, $button2, $Checkbox1, $Checkbox2 $Form1 = GUICreate("Form1", 633, 454, 187, 113) $Label1 = GUICtrlCreateLabel("Select a Program to install", 32, 48, 126, 17) $Checkbox1 = GUICtrlCreateCheckbox("Checkbox1", 80, 90, 17, 17) $Label2 = GUICtrlCreateLabel("Nero 8 Essentials Suite 2", 112, 90, 129, 17) $Checkbox2 = GUICtrlCreateCheckbox("Checkbox2", 80, 105, 17, 17) $Label3 = GUICtrlCreateLabel("E-Trust 7.1 OEM", 112, 105, 129, 17) $Button1 = GUICtrlCreateButton("Start", 48, 304, 129, 25, 0) GUISetState() While 1 $Msg = GuiGetMsg() Switch $Msg Case $GUI_EVENT_CLOSE Exit Case $button1 $fSelected = False if BitAND(GUICtrlRead($Checkbox1), $GUI_CHECKED) then MsgBox (0, "howdy", "This installs Nero") $fSelected = True EndIf if BitAND(GUICtrlRead($Checkbox2), $GUI_CHECKED) Then MsgBox (0, "howdy", "This installs E-Trust") $fSelected = True EndIf If $fSelected = False Then MsgBox (0, "error", "Nothing was selected!") EndSwitch WEnd Ask again if it is not right - I might try a third time! M23 I wanted a script that installs selected programs, based it on that script and works it fine Now here's the thing, actually two things. I would like the script to give a message when it's done and then after clicking OK it exits. I can't seem to find an exit command plus I can't get it to display a message after the programs are done installing. This is what I've got now: #include <GUIConstants.au3> Local $Msg, $button1, $button2, $Checkbox1, $Checkbox2 $Form1 = GUICreate("Programma installatiescript", 600, 450, 187, 113) $Label1 = GUICtrlCreateLabel("Selecteer de programma's die je wil installeren:", 10, 10, 250, 17) $Checkbox1 = GUICtrlCreateCheckbox("Checkbox1", 10, 37, 17, 17) $Label2 = GUICtrlCreateLabel("Office 2007", 27, 39, 129, 17) $Checkbox2 = GUICtrlCreateCheckbox("Checkbox2", 10, 54, 17, 17) $Label3 = GUICtrlCreateLabel("Nero Burning Rom", 27, 56, 129, 17) $Button1 = GUICtrlCreateButton("Start", 235, 415, 130, 25, 0) GUISetState() While 1 $Msg = GuiGetMsg() Switch $Msg Case $GUI_EVENT_CLOSE Exit Case $button1 $fSelected = False if BitAND(GUICtrlRead($Checkbox1), $GUI_CHECKED) then RunWait ("Office_2007_NL\setup.exe /config config.xml") $fSelected = True EndIf if BitAND(GUICtrlRead($Checkbox2), $GUI_CHECKED) Then RunWait ("Ahead\Nero-6.6.0.18_setup\Setupx.exe /silent /noreboot /no_ui") RunWait ("Ahead\Nero-6.6.0.18_nld_languagepack\Setup.exe /silent /noreboot /no_ui") $fSelected = True EndIf If $fSelected = False Then MsgBox (0, "Error", "Je hebt geen programma's geselecteerd!") EndSwitch WEnd MsgBox (0, "Klaar!", "Alle geselecteerde programma's zijn geïnstalleerd!") The MsgBOX at the end would be the one mentioning that the script is done installing the selected programs, but it doesn't appear. Note: I'm completely new with AutoIt, but I understand how the script works
Moderators Melba23 Posted June 10, 2010 Moderators Posted June 10, 2010 bartgrefte,You need to put the MsgBox where it will be run - at the moment you have it outside the While...WEnd loop which means it never runs.As you need to press the button to get the installer to start, just put the MsgBox at the end of the Case $button1 code like this:While 1 Switch GUIGetMsg() Case $GUI_EVENT_CLOSE Exit Case $button1 $fSelected = False If BitAND(GUICtrlRead($Checkbox1), $GUI_CHECKED) Then ConsoleWrite("Office" & @CRLF) ;RunWait ("Office_2007_NL\setup.exe /config config.xml") $fSelected = True EndIf If BitAND(GUICtrlRead($Checkbox2), $GUI_CHECKED) Then ConsoleWrite("Nero" & @CRLF) ;RunWait ("Ahead\Nero-6.6.0.18_setup\Setupx.exe /silent /noreboot /no_ui") ;RunWait ("Ahead\Nero-6.6.0.18_nld_languagepack\Setup.exe /silent /noreboot /no_ui") $fSelected = True EndIf If $fSelected = False Then MsgBox(0, "Error", "Je hebt geen programma's geselecteerd!") Else MsgBox(0, "Klaar!", "Alle geselecteerde programma's zijn geïnstalleerd!") Exit EndIf EndSwitch WEndNow when you run the $button1 code, you get either the "nothing selected" MsgBox or the "All done" one. I have added an Exit after the "All done" to exit the script as you wished. There is also an Exit in the Case $GUI_EVENT_CLOSE code to quit when the [X] is pressed.Is everything clear? M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area
bartgrefte Posted June 10, 2010 Posted June 10, 2010 Ah, like that. So simple that I did not see it Thanks! Gonna try that later on, just now I've been working on getting the script to install CoreAVC.... The 1.9.* versions were a pain in the but, since the silent install switch did not work. Well, it worked, but it was expecting an installation code that I could not enter with a switch, the install ended before even starting. If you ask, putting the registration info into the registry before install did not help.... So after a while I came up with this (when I still was using a batch): CD %programfiles% MD CoreCodec CD CoreCodec MD "CoreAVC Professional Edition" CD "CoreAVC Professional Edition" COPY %cdrom%\Install\CoreAVC1.9.5.0\programfiles\*.* "%programfiles%\CoreCodec\CoreAVC Professional Edition" CD "C:\Documents and Settings\Administrator\Menu Start\Programma's" MD CoreCodec CD CoreCodec MD "CoreAVC Professional Edition" CD "CoreAVC Professional Edition" COPY %cdrom%\Install\CoreAVC1.9.5.0\startmenu\*.* "C:\Documents and Settings\Administrator\Menu Start\Programma's\CoreCodec\CoreAVC Professional Edition" start /wait REGEDIT /S %cdrom%\Install\CoreAVC1.9.5.0\CoreAVC_Registered_User.reg start %systemroot%\system32\rundll32.exe "C:\Program Files\CoreCodec\CoreAVC Professional Edition\CoreAVCDecoder.ax",DllRegisterServer COPY %cdrom%\Install\CoreAVC1.9.5.0\programfiles\CoreAVCDecoder.ax %systemroot%\system32 regsvr32 /s coreavcdecoder.ax I did a normal install first, then I made a copy of CoreAVC's programfiles folder and startmenu folder and I put the registry info in a reg key.. Now this would not work for some reason with 2.0, however, 2.0 does have a working silent install switch now. So I let the AutoIt-script do this: RunWait("REGEDIT /S CoreAVC\coreavc.reg") RunWait("CoreAVC\Setup.exe /S") RunWait(@ComSpec & " /c " & "CoreAVC\coreavc_install.bat") where the batch does: start %systemroot%\system32\rundll32.exe "%programfiles%\CoreCodec\CoreAVC Professional Edition\CoreAVCDecoder.ax",DllRegisterServer COPY "%programfiles%\CoreCodec\CoreAVC Professional Edition\CoreAVCDecoder.ax" "%systemroot%\system32" regsvr32 /s coreavcdecoder.ax I always hate it when programs can't be installed using a simple /S like switch, with CoreAVC I had to be creative. Now if I could only find a way to install Alcohol 120% silently as well, still haven't found a way for that. But now I am way offtopic
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now