styles3000 Posted January 18, 2010 Share Posted January 18, 2010 I ran this small piece of code by itself .......... $sTotalFiles = _GetFileCount("D:Documents and SettingsTaevon JonesDesktopExtracted Keywords") ;MsgBox(0,'Total Files',$sTotalFiles) sleep(7000) For $i = 1 To $sTotalFiles FileCopy('D:Documents and SettingsTaevon JonesDesktopPAGE-MASTER-PHP.htm', _ 'D:Documents and SettingsTaevon JonesMy DocumentsOne a be HyperVRE Webpages' & $Firstline & 'index' & $i & '.htm',8) Next and it worked perfectly. But when I placed it in the GUI script, nothing happens. Has anyone had this type of problem before? Link to comment Share on other sites More sharing options...
MvGulik Posted January 18, 2010 Share Posted January 18, 2010 (edited) whatever Edited February 7, 2011 by MvGulik "Straight_and_Crooked_Thinking" : A "classic guide to ferreting out untruths, half-truths, and other distortions of facts in political and social discussions.""The Secrets of Quantum Physics" : New and excellent 2 part documentary on Quantum Physics by Jim Al-Khalili. (Dec 2014) "Believing what you know ain't so" ... Knock Knock ... Link to comment Share on other sites More sharing options...
styles3000 Posted January 18, 2010 Author Share Posted January 18, 2010 What happened to your filespec delimiters? If thats the code your trying to run the problem is rather obvious. Code master MvGulik, Thanks for your input. A buddy of mine says that incorrect though. expandcollapse popup#include <ButtonConstants.au3> #include <GUIConstantsEx.au3> #include <ListBoxConstants.au3> #include <WindowsConstants.au3> #include <IE.au3> #Include <Array.au3> #include <file.au3> #include <EditConstants.au3> Global $split, $FirstLine,$List2 $Form1_1 = GUICreate("Form1", 609, 414, 186, 127) $Button1 = GUICtrlCreateButton("Get Popular Keyword ", 32, 40, 241, 25) $Button2 = GUICtrlCreateButton("Website Creation", 32, 136, 241, 33) $Button3 = GUICtrlCreateButton("Generate Subtopic Keywords", 440, 40, 139, 33, 0) $Button4 = GUICtrlCreateButton("Generate Websites", 32, 272, 243, 49) $List1 = GUICtrlCreateEdit(""&@CRLF&"", 280, 72, 129, 357) ; added "act"&@CRLF&"aig" for testing $Button5 = GUICtrlCreateButton("Import Keywords", 296, 40, 105, 33) $List2 = GUICtrlCreateEdit("", 440, 72, 137, 266) GUICtrlSetData(-1, "") $Button6 = GUICtrlCreateButton("Import Keywords 2", 456, 344, 105, 25, 0) GUISetState(@SW_SHOW) While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $Button1 _Button1_Pressed() Case $Button5 _GetKeywords() ;-----------------------------------------------o0o0o0o0o0o0o0o0o0o0o0o0o0o0o0o0o0o0o0o0o0o0o0o0o0o0o0o0 Sleep(3000) _PopulateKeyWords() Case $Button3 ;_Button3_Pressed() _Button3_Pressed_NEW() Case $Button2 $ResultsOfRead = GUICtrlRead($List2) $FirstLine = StringMid($ResultsOfRead,1,StringInStr($ResultsOfRead,@CRLF)) ClipPut($FirstLine) _Button2_Pressed() Case $Button6 ;this i did add _Button6_Pressed() Case $Button4 $ResultsOfRead = GUICtrlRead($List2) $FirstLine = StringMid($ResultsOfRead,1,StringInStr($ResultsOfRead,@CRLF)) ClipPut($FirstLine) _Button4_Pressed() EndSwitch WEnd Func _code_will_work $sTotalFiles = _GetFileCount("D:\Documents and Settings\Taevon Jones\Desktop\Extracted Keywords\") ;MsgBox(0,'Total Files',$sTotalFiles) sleep(7000) DirCreate('D:\Documents and Settings\Taevon Jones\My Documents\One a be HyperVRE Webpages\'&$Firstline) FileCopy('D:\Objects To Burn\Adsense\websites\HOME-MASTER-PHP2.htm', _ 'D:\Documents and Settings\Taevon Jones\My Documents\One a be HyperVRE Webpages\'&$Firstline&'\index.htm',8) sleep(5000) For $i = 1 To $sTotalFiles FileCopy('D:\Documents and Settings\Taevon Jones\Desktop\PAGE-MASTER-PHP.htm', _ 'D:\Documents and Settings\Taevon Jones\My Documents\One a be HyperVRE Webpages\' & $Firstline & '\index' & $i & '.htm',8) Next endfunc When I run it outside of the GUI, it works fine. But nothing happens. Link to comment Share on other sites More sharing options...
MvGulik Posted January 18, 2010 Share Posted January 18, 2010 (edited) whatever Edited February 7, 2011 by MvGulik "Straight_and_Crooked_Thinking" : A "classic guide to ferreting out untruths, half-truths, and other distortions of facts in political and social discussions.""The Secrets of Quantum Physics" : New and excellent 2 part documentary on Quantum Physics by Jim Al-Khalili. (Dec 2014) "Believing what you know ain't so" ... Knock Knock ... 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