sfwd001 发表于 2009-10-20 11:33:30

求助怎么打开系统属性窗口

想修改XP系统属性中的虚拟盘符位置,可是在做的过程中,第一步就出现问题了,不知道用AUTOIT3怎么才能把桌面“我的电脑”属性窗口打开。鼠标实际操作就是:右击--我的电脑--属性--左击 就可以打开了,这个步骤怎么才能使用Autoit3自动操作呢?

sfwd001 发表于 2009-10-20 11:34:08

自己顶一下,求大家帮助,在线等,谢谢!

netegg 发表于 2009-10-20 11:55:13

本帖最后由 netegg 于 2009-10-20 11:56 编辑

那不是打开控制面板里的系统吗,找找看对应文件名(忘了),execute就行了
另外,论坛里有一个帖子,专门介绍过这个,查查看

lpxx 发表于 2009-10-20 12:29:00

Send("{lwindown}{pause}{lwinup}")

lpxx 发表于 2009-10-20 12:29:23

Run(@COMSPEC & " /c rundll32.exe shell32.dll,Control_RunDLL sysdm.cpl,,0","",@SW_HIDE)

lpxx 发表于 2009-10-20 12:32:13

调用系统的关机对话框Run("rundll32.exe shell32.dll #60")

lpxx 发表于 2009-10-20 12:34:26

另外,这个代码是我收集的,我不是原作者,给你参考一下。
#include <GUIConstants.au3>
$Form1_1 = GUICreate("Many Buttons", 479, 341, -1, -1)
GUISetFont(9, 400, 0, "Georgia")
$Tab1 = GUICtrlCreateTab(4, 4, 472, 300)
GUICtrlSetFont(-1, 9, 400, 0, "Georgia")
GUICtrlSetResizing(-1, $GUI_DOCKWIDTH+$GUI_DOCKHEIGHT)
$Button11 = GUICtrlCreateButton("电脑属性", 24, 48, 89, 25, 0)
$Button12 = GUICtrlCreateButton("显示属性", 24, 83, 89, 25, 0)
$Button13 = GUICtrlCreateButton("电源选项", 24, 152, 89, 25, 0)
$Button14 = GUICtrlCreateButton("网络连接", 24, 117, 89, 25, 0)
$Button16 = GUICtrlCreateButton("用户帐户", 24, 256, 89, 25, 0)
$Button17 = GUICtrlCreateButton("安全中心", 24, 221, 89, 25, 0)
$Button18 = GUICtrlCreateButton("磁盘管理", 24, 187, 89, 25, 0)
$Button15 = GUICtrlCreateButton("添加删除程序", 136, 256, 89, 25, 0)
$Button19 = GUICtrlCreateButton("磁盘碎片整理", 136, 221, 89, 25, 0)
$Button20 = GUICtrlCreateButton("声音属性", 136, 187, 89, 25, 0)
$Button21 = GUICtrlCreateButton("命令提示符", 136, 152, 89, 25, 0)
$Button22 = GUICtrlCreateButton("任务管理器", 136, 117, 89, 25, 0)
$Button23 = GUICtrlCreateButton("计算机管理", 136, 83, 89, 25, 0)
$Button24 = GUICtrlCreateButton("设备管理器", 136, 48, 89, 25, 0)
$Button25 = GUICtrlCreateButton("计算器", 248, 256, 89, 25, 0)
$Button26 = GUICtrlCreateButton("NotePad", 248, 221, 89, 25, 0)
$Button27 = GUICtrlCreateButton("MS Paint", 248, 187, 89, 25, 0)
$Button28 = GUICtrlCreateButton("Dr.Watson", 248, 152, 89, 25, 0)
$Button29 = GUICtrlCreateButton("MsConfig", 248, 117, 89, 25, 0)
$Button30 = GUICtrlCreateButton("DxDiag", 248, 83, 89, 25, 0)
$Button31 = GUICtrlCreateButton("Regedit", 248, 48, 89, 25, 0)
$Button32 = GUICtrlCreateButton("资源管理器", 360, 256, 89, 25, 0)
$Button33 = GUICtrlCreateButton("回收站", 360, 221, 89, 25, 0)
$Button34 = GUICtrlCreateButton("临时文件夹", 360, 187, 89, 25, 0)
$Button35 = GUICtrlCreateButton("Wallpaper", 360, 152, 89, 25, 0)
$Button36 = GUICtrlCreateButton("Windows目录", 360, 117, 89, 25, 0)
$Button37 = GUICtrlCreateButton("System目录", 360, 83, 89, 25, 0)
$Button38 = GUICtrlCreateButton("资源管理器", 360, 48, 89, 25, 0)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###
While 1
$nMsg = GUIGetMsg()
Switch $nMsg
   Case $GUI_EVENT_CLOSE
    Exit   
   Case $Button11 ;"电脑属性", 24, 48, 89, 25, 0)
    Run(@ComSpec & " /c " & 'sysdm.cpl', "", @SW_HIDE)
   Case $Button12 ;"显示属性", 24, 83, 89, 25, 0)
    Run(@ComSpec & " /c " & 'desk.cpl', "", @SW_HIDE)
   Case $Button13 ;"电源选项", 24, 152, 89, 25
    Run(@ComSpec & " /c " & 'powercfg.cpl', "", @SW_HIDE)
   Case $Button14 ;"网络连接", 24, 117, 89, 25
    Run(@ComSpec & " /c " & 'ncpa.cpl', "", @SW_HIDE)
   Case $Button16 ;"用户帐户", 24, 256, 89, 25
    Run(@ComSpec & " /c " & 'nusrmgr.cpl', "", @SW_HIDE)
   Case $Button17 ;"安全中心", 24, 221, 89, 25
    Run(@ComSpec & " /c " & 'wscui.cpl', "", @SW_HIDE)
   Case $Button18 ;"磁盘管理", 24, 187, 89, 25
    Run(@ComSpec & " /c " & 'diskmgmt.msc', "", @SW_HIDE)
   Case $Button15 ;"添加删除程序", 136, 256, 89, 25
    Run(@ComSpec & " /c " & 'appwiz.cpl', "", @SW_HIDE)
   Case $Button19 ;"磁盘整理", 136, 221, 89, 25
    Run(@ComSpec & " /c " & 'dfrg.msc', "", @SW_HIDE)
   Case $Button20 ;"声音属性", 136, 187, 89, 25
    Run(@ComSpec & " /c " & 'sndvol32', "", @SW_HIDE)
   Case $Button21 ;"命令提示符", 136, 152, 89, 25
    Run(@ComSpec & " /c " & 'cmd.exe', "", @SW_SHOW)
   Case $Button22 ;"任务管理器", 136, 117, 89, 25
    Run(@ComSpec & " /c " & 'taskmgr', "", @SW_HIDE)
   Case $Button23 ;"计算机管理", 136, 83, 89, 25
    Run(@ComSpec & " /c " & 'compmgmt.msc', "", @SW_HIDE)
   Case $Button24 ;"设备管理器", 136, 48, 89, 25
    Run(@ComSpec & " /c " & 'devmgmt.msc', "", @SW_HIDE)
   Case $Button25 ;"计算器", 248, 256, 89, 25
    Run(@ComSpec & " /c " & 'calc', "", @SW_HIDE)
   Case $Button26 ;"NotePad", 248, 221, 89, 25
    Run(@ComSpec & " /c " & 'notepad', "", @SW_HIDE)
   Case $Button27 ;"MS Paint", 248, 187, 89, 25
    Run(@ComSpec & " /c " & 'mspaint', "", @SW_HIDE)
   Case $Button28 ;"Dr.Watson", 248, 152, 89, 25
    Run(@ComSpec & " /c " & 'drwtsn32', "", @SW_HIDE)
   Case $Button29 ;"MsConfig", 248, 117, 89, 25
    Run(@WindowsDir & "\pchealth\helpctr\binaries\msconfig.exe")
   Case $Button30 ;"DxDiag", 248, 83, 89, 25
    Run(@ComSpec & " /c " & 'dxdiag', "", @SW_HIDE)
   Case $Button31 ;"Regedit", 248, 48, 89, 25
    Run(@ComSpec & " /c " & 'regedit', "", @SW_HIDE)
   Case $Button32 ;"资源管理器", 360, 256, 89, 25
    Run(@ComSpec & " /c " & 'explorer', "", @SW_HIDE)
   Case $Button33 ;"回收站", 360, 221, 89, 25
    Run(@ComSpec & " /c " & 'explorer ::{645FF040-5081-101B-9F08-00AA002F954E}', "", @SW_HIDE)
   Case $Button34 ;"临时文件夹", 360, 187, 89, 25
    Run(@ComSpec & " /c " & 'explorer '&@TempDir, "", @SW_HIDE)
   Case $Button35 ;"Wallpaper", 360, 152, 89, 25
    Run(@ComSpec & " /c " & 'explorer '&@WindowsDir&'\web\wallpaper', "", @SW_HIDE)
   Case $Button36 ;"Windows目录", 360, 117, 89, 25
    Run(@ComSpec & " /c " & 'explorer '&@WindowsDir, "", @SW_HIDE)
   Case $Button37 ;"System目录", 360, 83, 89, 25
    Run(@ComSpec & " /c " & 'explorer '&@SystemDir, "", @SW_HIDE)
   Case $Button38 ;"资源管理器", 360, 48, 89, 25
    Run(@ComSpec & " /c " & 'explorer', "", @SW_HIDE)
EndSwitch
WEnd

mshuking 发表于 2009-10-20 16:01:58

好多,记下。。。。

wyl0205 发表于 2009-12-22 01:42:57

做个记号,备用

fyq 发表于 2013-8-14 14:45:31

学到不少东东了,谢谢

cuihairu 发表于 2014-1-7 12:47:23

_RunDOS("c:\windows\system32\sysdm.cpl")
页: [1]
查看完整版本: 求助怎么打开系统属性窗口