boswells Posted March 9, 2005 Share Posted March 9, 2005 I'm working on trying to put together a small little script that will enable the end user to runas admin when opening network properties in control panel. I tried this: RunAsSet("administrator", "machine name", "password") run("control powercfg.cpl") and even Run("RUNDLL32 SHELL32.DLL,Control_RunDLL ncpa.cpl") which works fine on my machine, but it just isn't working on the user machine. I noticed that the ncpa.cpl file is in C:\i386 on the user PC whereas on my PC it's in c:\windows\system32\. am I missing something really easy here? Also wondered if there was a way in which we could use the runasset command without the machine name to save having to modify the au3 file every time it needs to be used on a different machine. Any advice would be greatly appreciated. I'm afriad I'm very new to this. Thank you! Link to comment Share on other sites More sharing options...
boswells Posted March 9, 2005 Author Share Posted March 9, 2005 WinXP SP2 Link to comment Share on other sites More sharing options...
boswells Posted March 9, 2005 Author Share Posted March 9, 2005 silliness on my part. It IS in system32 (my search criteria was too narrow). When I try to run this script, the root directory opens. Very weird. I'll keep working on it. Link to comment Share on other sites More sharing options...
CyberSlug Posted March 9, 2005 Share Posted March 9, 2005 (edited) I can confirm the behavior on XP SP2. Most *.cpl files EXCEPT ncpa.cpl work....Try right-clicking ncpa.cpl and doing a Run As... that also fails. I imagine that the "Network Connections" actually references some funky shell folderASIDE: Prior to SP2 I was able to use ShellObject Editor to put "My network places" and "Recycle Bin" inside "My Computer" instead of on the desktop. SP2 broke the special "My network places" shortcut Edited March 9, 2005 by CyberSlug Use Mozilla | Take a look at My Disorganized AutoIt stuff | Very very old: AutoBuilder 11 Jan 2005 prototype I need to update my sig! Link to comment Share on other sites More sharing options...
CyberSlug Posted March 9, 2005 Share Posted March 9, 2005 You need the full path to Internet Explorer Run(@ProgramFilesDir & "\Internet Explorer\iexplore.exe" & " ::{20D04FE0-3AEA-1069-A2D8-08002B30309D}\::{21EC2020-3AEA-1069-A2DD-08002B30309D}\::{7007ACC7-3202-11D1-AAD2-00805FC1270E}") Use Mozilla | Take a look at My Disorganized AutoIt stuff | Very very old: AutoBuilder 11 Jan 2005 prototype I need to update my sig! 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