Jump to content

Gnomercy

Members
  • Posts

    9
  • Joined

  • Last visited

Gnomercy's Achievements

Seeker

Seeker (1/7)

0

Reputation

  1. and appears wrong. Tested your function w/the following test $var = "simple test" $ret = _String2Binary($var) ConsoleWrite("$ret - "&$ret&@CRLF) $msg = _Binary2String($ret) ConsoleWrite("$msg - "&$msg&@CRLF) -------Output------- $ret - 0111001101101001011100110110110101101001011100110111000001101101011010010111001101101100011100000110 1101011010010111001101100101011011000111000001101101011010010111001100100000011001010110110001110000 0110110101101001011100110111010000100000011001010110110001110000011011010110100101110011011001010111 0100001000000110010101101100011100000110110101101001011100110111001101100101011101000010000001100101 0110110001110000011011010110100101110011011101000111001101100101011101000010000001100101011011000111 0000011011010110100101110011 $msg - ssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssss
  2. For those who just needs to run an existing .reg file named myregfile.reg in c:\ run("c:\windows\regedit.exe /s c:\myregfile.reg")
  3. How would you do it if the tree you're searching is many folders deep without using recursion? I think i can see the nested loop working on stuff one folder deep. But for trees like c:\program files where you don't know what you'll get I am not seeing it. One problem that I am having with my method is how to efficiently break a paragraph of text into an array. I tried using Stringsplit on @cr, I get funny squares when it's written to a dos text file. I am sure it has to do with the 2 char CRLF windows uses to end string. I am currently writing the block of text to a file and reading it back in line by line. if anyone has a better solution I am game. /blow whistle, throw a yellow flag i know this isn't tech support.. at least i did have a solution
  4. Been leaching people's code so here something trivial to give back to community (requires beta) Any critique or question is most welcomed. #include<Constants.au3> ;Uses dos command to recurse a folder indicated by $source_path ;Note: filtes can be added (ie searching for .mp3 change $source_path to ;$source_path ="C:\Program Files\AutoIt3\*.mp3" $source_path ="C:\Program Files\AutoIt3" $dir = RecurseDir($source_path) MsgBox(0, "$dir", $dir) func RecurseDir($source_path) Local $output, $var, $foo, $line_out, $line_stderr $var = @ComSpec&' /C dir "'&$source_path&'" /s /b /a-d' ConsoleWrite($var&@lf) $foo = run($var, $source_path, @SW_ENABLE, $STDERR_CHILD + $STDOUT_CHILD) $output="" While 1 $line_out = StdoutRead($foo) If @error = -1 Then ExitLoop $output = $output&$line_out Wend While 1 $line_stderr = StderrRead($foo) If @error = -1 Then ExitLoop MsgBox(0, "ERROR of Greatest Proportions", "CodeSuck: "&$line_stderr) Exit Wend return $output EndFuncmyCurseDir.au3
  5. I've been trying a number of stuff Namely AutoItSetOption("WinTitleMatchMode", 4) WinActivate ( "Rhapsody") ;$var = ControlFocus("Rhapsody", "", "ClassNameNN=TEST_WIN32WND55") ;$var=ControlCommand("Rhapsody", "", "ClassName=TEST_WIN32WND55", "IsEnabled", "") ;$var = ControlFocus("Rhapsody", "", "ClassNameNN=TEST_WIN32WND85") ;$var = ControlClick("ClassNameNN=TEST_WIN32WND85") ;$var = ControlClick('ClassNameNN=TEST_WIN32WND85', "") $var = ControlClick("Rhapsody", "", "ClassNameNN=TEST_WIN32WND85") MsgBox(0, "Control Focus", $var) ;Returns 0 :( ;ControlCommand("Rhapsody", "", "ClassName=TEST_WIN32WND55", "EditPaste", 'Sum 41') The problem is that I am unable to click on controls based on the ClassNameNN. Am I doing this right? I tried looking in the help and forums. The help only infers that ClassNameNN can be used to identify a window. But there's nothing for it in controls. I want to be able to ControlFocus, ControlClick, Send and all the normal stuff. But using the ClassName as an ID isn't working for me BTW Thanks for your help it's much appreciated.
  6. The problem with ControlCommand is that it requires a ControlID.The AutoIt Active WindowInfo reports no ID but offers a class name. Is there another control where I can pass the classname or Handle for situations like this? Press CTRL-ALT-F to pause the display. >>>>>>>>>>>> Window Details <<<<<<<<<<<<< Title: Rhapsody Class: TEST_WIN32WND Size: X: 18 Y: 58 W: 987 H: 766 >>>>>>>>>>> Mouse Details <<<<<<<<<<< Screen: X: 546 Y: 479 Cursor ID: 0 >>>>>>>>>>> Pixel Color Under Mouse <<<<<<<<<<< RGB: Hex: 0xDEE7F0 Dec: 14608368 >>>>>>>>>>> Control Under Mouse <<<<<<<<<<< Size: X: 434 Y: 256 W: 539 H: 463 Control ID: ClassNameNN: MFCReportCtrl5 Text: searchresults.external Style: 0x5210282A ExStyle: 0x00000000 (Control is hidden) >>>>>>>>>>> Status Bar Text <<<<<<<<<<<
  7. I am trying to automate stuff in Rhapsody but like most music apps, iTunes, WindowsMediaPlayer they've got the Music Stores. AutoIt doesn't like these too well. WinSpy shows these as Internet Explorer_Server class. I've tried digging through the forums and have played around with beta and the com objects. But everything I've read so far have been about stand alone Internet Explorer. I am a noob to com and have been toying w/AutoIt for a few days now. Can a pro point me to some example code or give some search phrase to continue my search. How do you automate a web page that is inside an application? Thanks, Gnomy
×
×
  • Create New...