top Posted April 11, 2006 Share Posted April 11, 2006 my code doesnt work ;( please help. thanks in advance $file = FileOpen("random.txt", 0) $line = FileReadLine($file) Run("notepad.exe") WinWait("Untitled -") ControlSetText("Untitled -", "", "Edit1", "$line" ) FileClose($file) Link to comment Share on other sites More sharing options...
flaxcrack Posted April 11, 2006 Share Posted April 11, 2006 my code doesnt work ;( please help. thanks in advance $file = FileOpen("random.txt", 0) $line = FileReadLine($file) Run("notepad.exe") WinWait("Untitled -") ControlSetText("Untitled -", "", "Edit1", "$line" ) FileClose($file) $file = "random.txt" FileOpen($file) $line = FileReadLine($file) Run("notepad.exe") WinWait("Untitled -") ControlSetText("Untitled -", "", "Edit1", "$line" ) FileClose($file) [quote] Gilbertson's Law: Nothing is foolproof to a sufficiently talented fool.Sandro Alvares: Flaxcrack is please not noob! i can report you is stop stupid. The Post[/quote]I made this: FWD & MD5PWD() Link to comment Share on other sites More sharing options...
top Posted April 11, 2006 Author Share Posted April 11, 2006 still doesnt work ;( Link to comment Share on other sites More sharing options...
GaryFrost Posted April 11, 2006 Share Posted April 11, 2006 ControlSetText("Untitled -", "", "Edit1", $line ) SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference. Link to comment Share on other sites More sharing options...
top Posted April 11, 2006 Author Share Posted April 11, 2006 (edited) $file = "random.txt" FileOpen($file, 0) $line = FileReadLine($file) Run("notepad.exe") WinWait("Untitled -") ControlSetText("Untitled -", "", "Edit1", $line ) FileClose($file) now works but how can i make to result a random line Edited April 11, 2006 by top Link to comment Share on other sites More sharing options...
Bert Posted April 11, 2006 Share Posted April 11, 2006 Random ( [Min [, Max [, Flag]]] ) The Vollatran project My blog: http://www.vollysinterestingshit.com/ Link to comment Share on other sites More sharing options...
GaryFrost Posted April 11, 2006 Share Posted April 11, 2006 #include <file.au3> $file = "random.txt" FileOpen($file, 0) $linecount = _FileCountLines($file) $num = Random(1,$linecount,1) $line = FileReadLine($file, $num) Run("notepad.exe") WinWait("Untitled -") ControlSetText("Untitled -", "", "Edit1", $line ) FileClose($file) SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference. Link to comment Share on other sites More sharing options...
top Posted April 11, 2006 Author Share Posted April 11, 2006 thank you. 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