Jump to content

RocTx

Active Members
  • Posts

    64
  • Joined

  • Last visited

RocTx's Achievements

Wayfarer

Wayfarer (2/7)

0

Reputation

  1. This one runs quite well for me. OS = Windows 7 Enterprise ; Fill in the username and password appropriate for your system. Local $sUserName = "Administrator" Local $sPassword = "PassWord" ; Run a command prompt as the other user. Local $pid = RunAsWait($sUserName, @ComputerName, $sPassword, 0, "dfrgui.exe", @SystemDir) ; Wait for the process to close. ProcessWaitClose($pid) Came right out of the Example code in the help file. RocTx
  2. I always thought "X Drop" was a good one. http://www.autoitscript.com/forum/index.ph...27&hl=xdrop RocTx
  3. Thanks for your reply SmOke_N, Your "Switch" code did not work for me. First it complained about not having "Select". Then when I added select it complained with a "syntax" error with "Switch". But from looking and using your example with "ConsoleWrite" I was able to code it as the following code and that worked! $Pressed=MsgBox (4131, "Accept?", "Is this Correct?" & @CRLF & @CRLF & ReadInput()) MsgBox(4096,"Pressed", "You Pressed " & $Pressed) Thanks again.. RocTx
  4. Thanks for the reply Alzo.. I've been there in that same page staring at it.. but I can't see "how" to determine which button was pressed, hence my question. What $variable or @function is the result in, that I can use to query or display what button was pressed? RocTx
  5. I need a nudge... How do you capture or determine what button was pressed in a MsgBox scenario. In the following code the flag 4131 produces a "Yes" "No" "Cancel" button. MsgBox (4131, "Accept?", "Is this Correct?" & @CRLF & @CRLF & ReadInput())How do I determine which one was pressed? Thanks
  6. Try the following tool to run it as a service Run As Service: http://www.pirmasoft.com/runassvc.php Or SrvAny: http://support.microsoft.com/kb/q137890/ RocTx Or this.. http://www.autoitscript.com/forum/index.ph...topic=15251&hl=
  7. I think you are still missing a space after your xcopy. You have "" instead of " " Doublecheck your "double quotes" for spaces left out. RocTx
  8. I have printed the entire Help file by selecting the top level "AutoIt" topic, then select print, then select "Print selected Heading and all subtopics". Be prepared to have a very thick book. So I only print it for every major version upgrade and not for beta releases. RocTx
  9. Excellent!!! The tool works perfectly! I have an IBM laptop connected with the onboard wired nic and also wifi. It detects both devices and I can select which adapter to view and all the correct information is there for them. I was working on a similar script to do the same.. except it was taking me longer. You beat me to it. But yours is great!! And I like it! Again.. thanks for sharing.. Food for thought and maybe new feature.. Adding the Name of the DHCP, Gateway and DNS servers for those who are curious. RocTx
  10. Very nice tool beshellenbaum. One slight bug... ( I think ).. In the Display function GUICTRLSetData ($subnet , $adapter[$result][5] ) GUICTRLSetData ($gateway , $adapter[$result][6] ) If using a "static ip".. the display is correct. However if using "dhcp" the display is off in the fact that it shows the subnet as the current ip address and the gateway as the subnet. If I change the 5 to a 6 then the subnet is displayed correctly. But I can't seem to get the gateway to display correctly. Changing it's value ([$result][x] does not seem to display the correct gateway ip. See attached images. Still going over the code.. Thanks for this very useful tool. RocTx
  11. I think burrup came up with this script that does what you want to do. #include <GUIConstants.au3> GUICreate("Test") $test1 = GUICtrlCreateInput ( "0000", 2, 2,40,-1,$ES_NUMBER) $test2 = GUICtrlCreateInput ( "This is a test", 2, 30,70,-1) $test3 = GUICtrlCreateLabel ( "text", 100, 2, 100, -1) GUISetState() $changed = GUICtrlRead ($test3) While 1 $msg = GUIGetMsg() If $msg = $GUI_EVENT_CLOSE Then ExitLoop If GUICtrlRead ($test1) > 9999 Then GUICtrlSetData ($test1, "9999") EndIf If $changed <> GUICtrlRead ($test1) & " - " & GUICtrlRead ($test2) Then GUICtrlSetData ($test3, GUICtrlRead ($test1) & " - " & GUICtrlRead ($test2)) EndIf $changed = GUICtrlRead ($test3) Wend I can't remember the thread/link to the original post. Burrup... this is correct no? Your code? RocTx
  12. @Xenogis; There seems to be an error in this logic because on Central time of 12:30pm the clock reads 2:30am. If @HOUR > 12 Then $h = @HOUR - 12 $pa = " PM" Else $h = StringTrimLeft ( @HOUR, 1 ) $pa = " AM" EndIf It seems like it does not take into account that 12:30pm is "not" greater than 12 and therefore falls throuth to the Else statement which ends up triming the "1" from the 12 and ends up being AM instead of PM. However, jdickens code works well. If $minute <> @MIN Then $minute = @MIN If @HOUR > 12 Then $TheHour = @HOUR - 12 Else $TheHour = @HOUR EndIf I know it's fixable, just thought I'd point that out. RocTx
  13. Who has the local admin password? Somebody has to have it no? Can your script prompt them to enter the password? Found this script (VB) to disable the firewall. You could "FileInstall" it and then run it. http://www.kayodeok.co.uk/weblog/200405/09...p_firewall.html Set objFirewall = CreateObject("HNetCfg.FwMgr") Set objPolicy = objFirewall.LocalPolicy.CurrentProfile objPolicy.FirewallEnabled = FALSE Hope it helps and gives you some ideas. RocTx
  14. Hmmmmm... This would be a good one for the "wiki". One central place to find it quickly instead of searching for it in the forum. Just an idea. RocTx
  15. I can confirm what Jdeb is seeing. I get the same thing. Win XP Pro SP2 AutoIt version 3.0.103.168 RocTx
×
×
  • Create New...