ptrex Posted March 9, 2007 Share Posted March 9, 2007 (edited) Control Panel Applets - Shortcuts and Scripts Using Control.exeThe parameter @m is used for files with more than one basic function and starts with zero,which is the default value if no parameter is used. For example, main.cpl controls both mouse and keyboard properties.Thus, either the commandcontrol main.cplorcontrol main.cpl,@0would open the mouse properties. To open the keyboard properties the command would becontrol main.cpl,@1The second set of optional parameters "n" can be used when a dialog box is tabbed.A number of the values are given in Table I. For example, the default window when the mouse properties dialog is openedis the "Buttons" tab. To open the"Pointer Options" tab (third on the list) the command would becontrol main.cpl,@0,2Note that here the index "n" is zero-based so the third tab has an index of 2.Many control panel files have only one main page and the "@m" index can be omitted. In that case, to open a particulartab requires two commas between the file name and the tab index. For example, the dialog box for System Properties has a numberof tabs as listed in the table above. A specific one of these can be opened by adding a parameter so that the command readscontrol.exe sysdm.cpl,,nwhere "n" is an integer running from 0 to 6 corresponding to the 7 tabs listed in Table I.Unfortunately, Microsoft is not consistent in how it indexes tabs. For example, when using access.cpl, the tabs run from 1 to 5instead of beginning with zero. Some files can only be opened at a few tabs or only at the beginning tab. For instance,Power Options has four tabs but they are not accessible with an index. The only way to find out what system applies to a particularfile seems to be trial and error. Also note that the numbering of tabs for many files is not the same in Windows XP as it was inWindows 98/Me. Also, at least one change was made in Windows XP SP2.; http://support.microsoft.com/default.aspx?scid=kb;EN-US;135068 ; Some Control Panel Applet Files ; ------------------------------- ; access.cpl Accessibility controls Keyboard(1), Sound(2), Display(3), Mouse(4), General(5) ; appwiz.cpl Add/Remove Programs ; desk.cpl Display properties Themes(5), Desktop(0), Screen Saver(1), Appearance (2), Settings(3) ; hdwwiz.cpl Add hardware ; inetcpl.cpl Configure Internet Explorer and ; Internet properties General(0), Security(1), Privacy(2), Content(3), Connections(4), Programs(5), Advanced(6) ; intl.cpl Regional settings Regional Options(1), Languages(2), Advanced(3) ; joy.cpl Game controllers ; main.cpl Mouse properties and settings Buttons(0), Pointers(1), Pointer Options(2), Wheel(3), Hardware(4) ; main.cpl,@1 Keyboard properties Speed(0), Hardware (1) ; mmsys.cpl Sounds and Audio Volume(0), Sounds(1), Audio(2), Voice(3), Hardware(4) ; ncpa.cpl Network properties ; nusrmgr.cpl User accounts ; powercfg.cpl Power configuration Power Schemes, Advanced, Hibernate, UPS (Tabs not indexed) ; sysdm.cpl System properties General(0), Computer Name(1), Hardware(2), Advanced(3), System Restore(4), ; Automatic Updates(5), Remote (6) ; telephon.cpl Phone and modem options Dialing Rules(0), Modems(1), Advanced(2) ; timedate.cpl Date and time properties Date & Time(0), Time Zone(1), Internet Time (no index) ; date/time.cpl Launches the Date and Time Properties window ; desktop.cpl Launches the Display Properties window ; color.cpl Launches the Display Properties window with the Appearance tab preselected ; ; Note that some CPL files are multi-functional and require additional parameters to invoke the various functions. ; Parameters use the "@" sign and a zero-based integer. ; Syntax : control somefile.cpl,<optional arguments> Run("control.exe sysdm.cpl,,4")Using these shortcuts you need to use LESS send() commands in your script to access the CTRL panels.Enjoy !!ptrex Edited September 14, 2012 by ptrex Gianni 1 Contributions :Firewall Log Analyzer for XP - Creating COM objects without a need of DLL's - UPnP support in AU3Crystal Reports Viewer - PDFCreator in AutoIT - Duplicate File FinderSQLite3 Database functionality - USB Monitoring - Reading Excel using SQLRun Au3 as a Windows Service - File Monitor - Embedded Flash PlayerDynamic Functions - Control Panel Applets - Digital Signing Code - Excel Grid In AutoIT - Constants for Special Folders in WindowsRead data from Any Windows Edit Control - SOAP and Web Services in AutoIT - Barcode Printing Using PS - AU3 on LightTD WebserverMS LogParser SQL Engine in AutoIT - ImageMagick Image Processing - Converter @ Dec - Hex - Bin -Email Address Encoder - MSI Editor - SNMP - MIB ProtocolFinancial Functions UDF - Set ACL Permissions - Syntax HighLighter for AU3ADOR.RecordSet approach - Real OCR - HTTP Disk - PDF Reader Personal Worldclock - MS Indexing Engine - Printing ControlsGuiListView - Navigation (break the 4000 Limit barrier) - Registration Free COM DLL Distribution - Update - WinRM SMART Analysis - COM Object Browser - Excel PivotTable Object - VLC Media Player - Windows LogOnOff Gui -Extract Data from Outlook to Word & Excel - Analyze Event ID 4226 - DotNet Compiler Wrapper - Powershell_COM - New Link to comment Share on other sites More sharing options...
MadBoy Posted March 10, 2007 Share Posted March 10, 2007 Great. Thanks for explaining use Will solve some of my problems. My little company: Evotec (PL version: Evotec) Link to comment Share on other sites More sharing options...
mikiutama Posted March 10, 2007 Share Posted March 10, 2007 wow... thanks a lot for this very usefull info.. this will definitely shorten my script and my time ... Link to comment Share on other sites More sharing options...
ptrex Posted March 10, 2007 Author Share Posted March 10, 2007 @MadBoy / mikiutama You are welcome ptrex Contributions :Firewall Log Analyzer for XP - Creating COM objects without a need of DLL's - UPnP support in AU3Crystal Reports Viewer - PDFCreator in AutoIT - Duplicate File FinderSQLite3 Database functionality - USB Monitoring - Reading Excel using SQLRun Au3 as a Windows Service - File Monitor - Embedded Flash PlayerDynamic Functions - Control Panel Applets - Digital Signing Code - Excel Grid In AutoIT - Constants for Special Folders in WindowsRead data from Any Windows Edit Control - SOAP and Web Services in AutoIT - Barcode Printing Using PS - AU3 on LightTD WebserverMS LogParser SQL Engine in AutoIT - ImageMagick Image Processing - Converter @ Dec - Hex - Bin -Email Address Encoder - MSI Editor - SNMP - MIB ProtocolFinancial Functions UDF - Set ACL Permissions - Syntax HighLighter for AU3ADOR.RecordSet approach - Real OCR - HTTP Disk - PDF Reader Personal Worldclock - MS Indexing Engine - Printing ControlsGuiListView - Navigation (break the 4000 Limit barrier) - Registration Free COM DLL Distribution - Update - WinRM SMART Analysis - COM Object Browser - Excel PivotTable Object - VLC Media Player - Windows LogOnOff Gui -Extract Data from Outlook to Word & Excel - Analyze Event ID 4226 - DotNet Compiler Wrapper - Powershell_COM - New Link to comment Share on other sites More sharing options...
GEOSoft Posted March 11, 2007 Share Posted March 11, 2007 You might want to take a look at this page (click on the Control Panel tab)http://dundats.mvps.org/Windows/Win98/98_Cmd_Switches.htmThe list is for Win 98 but it probably contains some that you don't have. George Question about decompiling code? Read the decompiling FAQ and don't bother posting the question in the forums.Be sure to read and follow the forum rules. -AKA the AutoIt Reading and Comprehension Skills test.*** The PCRE (Regular Expression) ToolKit for AutoIT - (Updated Oct 20, 2011 ver:3.0.1.13) - Please update your current version before filing any bug reports. The installer now includes both 32 and 64 bit versions. No change in version number. Visit my Blog .. currently not active but it will soon be resplendent with news and views. Also please remove any links you may have to my website. it is soon to be closed and replaced with something else. "Old age and treachery will always overcome youth and skill!" Link to comment Share on other sites More sharing options...
ptrex Posted March 12, 2007 Author Share Posted March 12, 2007 @GEOsoft Thanks for the link look a good reference website !! I didn't intend to make a exhaustive list of all the .CPL's. Just wanted to highlight the possibilities. So anyone else missing something can definitely use the website reference you gave Regards ptrex Contributions :Firewall Log Analyzer for XP - Creating COM objects without a need of DLL's - UPnP support in AU3Crystal Reports Viewer - PDFCreator in AutoIT - Duplicate File FinderSQLite3 Database functionality - USB Monitoring - Reading Excel using SQLRun Au3 as a Windows Service - File Monitor - Embedded Flash PlayerDynamic Functions - Control Panel Applets - Digital Signing Code - Excel Grid In AutoIT - Constants for Special Folders in WindowsRead data from Any Windows Edit Control - SOAP and Web Services in AutoIT - Barcode Printing Using PS - AU3 on LightTD WebserverMS LogParser SQL Engine in AutoIT - ImageMagick Image Processing - Converter @ Dec - Hex - Bin -Email Address Encoder - MSI Editor - SNMP - MIB ProtocolFinancial Functions UDF - Set ACL Permissions - Syntax HighLighter for AU3ADOR.RecordSet approach - Real OCR - HTTP Disk - PDF Reader Personal Worldclock - MS Indexing Engine - Printing ControlsGuiListView - Navigation (break the 4000 Limit barrier) - Registration Free COM DLL Distribution - Update - WinRM SMART Analysis - COM Object Browser - Excel PivotTable Object - VLC Media Player - Windows LogOnOff Gui -Extract Data from Outlook to Word & Excel - Analyze Event ID 4226 - DotNet Compiler Wrapper - Powershell_COM - New Link to comment Share on other sites More sharing options...
GEOSoft Posted March 12, 2007 Share Posted March 12, 2007 @GEOsoftThanks for the link look a good reference website !!I didn't intend to make a exhaustive list of all the .CPL's. Just wanted to highlight the possibilities. So anyone else missing something can definitely use the website reference you gave RegardsptrexYou're welcome. As long as people know that the Cpl tabs are zero based then they shouldn't have any problem creating there own list.I have the full list of standard cpl files and associated tabs for XP as well but I have not built that page yet.One of these days I'll get around to doing a script that searches for *.cpl and then gets all of the available tabs. George Question about decompiling code? Read the decompiling FAQ and don't bother posting the question in the forums.Be sure to read and follow the forum rules. -AKA the AutoIt Reading and Comprehension Skills test.*** The PCRE (Regular Expression) ToolKit for AutoIT - (Updated Oct 20, 2011 ver:3.0.1.13) - Please update your current version before filing any bug reports. The installer now includes both 32 and 64 bit versions. No change in version number. Visit my Blog .. currently not active but it will soon be resplendent with news and views. Also please remove any links you may have to my website. it is soon to be closed and replaced with something else. "Old age and treachery will always overcome youth and skill!" Link to comment Share on other sites More sharing options...
John C. Posted April 18, 2007 Share Posted April 18, 2007 You're welcome. As long as people know that the Cpl tabs are zero based then they shouldn't have any problem creating there own list.I have the full list of standard cpl files and associated tabs for XP as well but I have not built that page yet.One of these days I'll get around to doing a script that searches for *.cpl and then gets all of the available tabs.Open whole Control Panel$lnk = @StartMenuCommonDir&"\Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}"if Not FileExists($lnk) Then DirCreate($lnk)if FileExists($lnk) Then Run("RunAs /u:Administrator " & '"' & @ProgramFilesDir&"\Internet Explorer\IEXPLORE.EXE " & $lnk & '"') Link to comment Share on other sites More sharing options...
James Posted May 15, 2007 Share Posted May 15, 2007 Search google for run commands. This will give you a list of commands that can be used in the run box. And some other .cpls if they aren't in the example above. Blog - Seriously epic web hosting - Twitter - GitHub - Cachet HQ Link to comment Share on other sites More sharing options...
Jango Posted May 15, 2007 Share Posted May 15, 2007 @ptrex Thank you for these intresting script. In the same way I'm looking for a way to call the windows explorer dialog box to "Map a network drive" in AutoIt ... any idea ? Link to comment Share on other sites More sharing options...
ptrex Posted May 15, 2007 Author Share Posted May 15, 2007 @Jango I am afraid the NET NETWORK DRIVE is not an APPLET, so you can't use these tricks. But you could use the NET USE command in combination with RUN Syntax is Run("NET USE Z: \\Yourservername\Sharemame") Regards ptrex Contributions :Firewall Log Analyzer for XP - Creating COM objects without a need of DLL's - UPnP support in AU3Crystal Reports Viewer - PDFCreator in AutoIT - Duplicate File FinderSQLite3 Database functionality - USB Monitoring - Reading Excel using SQLRun Au3 as a Windows Service - File Monitor - Embedded Flash PlayerDynamic Functions - Control Panel Applets - Digital Signing Code - Excel Grid In AutoIT - Constants for Special Folders in WindowsRead data from Any Windows Edit Control - SOAP and Web Services in AutoIT - Barcode Printing Using PS - AU3 on LightTD WebserverMS LogParser SQL Engine in AutoIT - ImageMagick Image Processing - Converter @ Dec - Hex - Bin -Email Address Encoder - MSI Editor - SNMP - MIB ProtocolFinancial Functions UDF - Set ACL Permissions - Syntax HighLighter for AU3ADOR.RecordSet approach - Real OCR - HTTP Disk - PDF Reader Personal Worldclock - MS Indexing Engine - Printing ControlsGuiListView - Navigation (break the 4000 Limit barrier) - Registration Free COM DLL Distribution - Update - WinRM SMART Analysis - COM Object Browser - Excel PivotTable Object - VLC Media Player - Windows LogOnOff Gui -Extract Data from Outlook to Word & Excel - Analyze Event ID 4226 - DotNet Compiler Wrapper - Powershell_COM - New Link to comment Share on other sites More sharing options...
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