nht3004 Posted May 2, 2009 Share Posted May 2, 2009 (edited) How can I make a GUICtrlCreateInput() accept drag and drop files? I did like this, and it did not work: $browseFileLink=GUICtrlCreateInput("", 16, 64, 313, 21); GUICtrlSetFont(-1, 8, 400, 0, "Arial"); GUICtrlSetState($browseFileLink, $GUI_DROPACCEPTED); GUICtrlSetState($browseFileLink, $WS_EX_ACCEPTFILES); And please show me the way to decorate an Edit object in colors. Now I can only use 1 color for one Edit Object $help=GUICtrlCreateEdit("", 8, 32, 385, 225, $ES_READONLY); GUICtrlSetData(-1, "This is an example!"); GUICtrlSetFont(-1, 10, 400, 0, "Arial"); GUICtrlSetColor(-1, 0x800000); GUICtrlSetBkColor(-1, 0xFFFFFF); Thanks! Edited May 2, 2009 by nht3004 for(loop=0; loop<infinity; loop++) { alert('I love you'); } Link to comment Share on other sites More sharing options...
blakel Posted May 2, 2009 Share Posted May 2, 2009 you must use the extended style in GUICreate $WS_EX_ACCEPTFILES then GUICtrlCreateInput(blah GUICtrlSetState(-1,$GUI_DROPACCEPTED) Link to comment Share on other sites More sharing options...
nht3004 Posted May 2, 2009 Author Share Posted May 2, 2009 you must use the extended style in GUICreate $WS_EX_ACCEPTFILES then GUICtrlCreateInput(blah GUICtrlSetState(-1,$GUI_DROPACCEPTED)Is it bro, it did not work, either! $addInfoForm=GUICreate("Add more stuffs", 415, 280, "", "", $WS_EX_ACCEPTFILES); $browseFileLink=GUICtrlCreateInput("", 16, 64, 313, 21); GUICtrlSetFont(-1, 8, 400, 0, "Arial"); GUICtrlSetState($browseFileLink, $GUI_DROPACCEPTED); for(loop=0; loop<infinity; loop++) { alert('I love you'); } Link to comment Share on other sites More sharing options...
blakel Posted May 2, 2009 Share Posted May 2, 2009 $addInfoForm=GUICreate("Add more stuffs", 415, 280, -1,-1,-1, $WS_EX_ACCEPTFILES); Link to comment Share on other sites More sharing options...
nht3004 Posted May 2, 2009 Author Share Posted May 2, 2009 $addInfoForm=GUICreate("Add more stuffs", 415, 280, -1,-1,-1, $WS_EX_ACCEPTFILES);Thanks bro, it worked, wonderful for(loop=0; loop<infinity; loop++) { alert('I love you'); } Link to comment Share on other sites More sharing options...
blakel Posted May 2, 2009 Share Posted May 2, 2009 welcome Link to comment Share on other sites More sharing options...
nht3004 Posted May 2, 2009 Author Share Posted May 2, 2009 I have sth forgot to ask you, please show me the way to make a variable used through 2 programs.Example, I have a INDEX.au3Run(@ScriptDir, "chk.exe"); chk.exe is compiled from chk.au3 If($logIn=1) Then MsgBox(0,"","Loged in"); Else MsgBox(0,"","Not Logged In Yet"); EndIfAnd in chk.au3Global $logIn; $logIn=1;When I run that script, it always show me "Not Logged In Yet" because 2 programs are obviously different.Any ideas to solve this problem guys?^^! for(loop=0; loop<infinity; loop++) { alert('I love you'); } Link to comment Share on other sites More sharing options...
blakel Posted May 2, 2009 Share Posted May 2, 2009 Command Line args ipc or named pipes temp file temp reg key tcp via loopback change the file descriptors move it all to one script Link to comment Share on other sites More sharing options...
nht3004 Posted May 2, 2009 Author Share Posted May 2, 2009 (edited) Command Line argsipc or named pipestemp filetemp reg keytcp via loopbackchange the file descriptorsmove it all to one scriptI'm using the way that create the reg string in regedit, but I have to delete it by-hand. Any way to make it temp, or use temp files, show me details, thanks for your idea ! Edited May 2, 2009 by nht3004 for(loop=0; loop<infinity; loop++) { alert('I love you'); } Link to comment Share on other sites More sharing options...
blakel Posted May 2, 2009 Share Posted May 2, 2009 Script one: RegWrite(authenicated Script two: RegRead RegDelete Link to comment Share on other sites More sharing options...
nht3004 Posted May 2, 2009 Author Share Posted May 2, 2009 Script one:RegWrite(authenicatedScript two:RegReadRegDeleteOops, but there seems to be a problem. It can not be deleted itself, so when the program is closed ( people deleted neccessary file for instance), the reg key is still there, and my program can be infected!! for(loop=0; loop<infinity; loop++) { alert('I love 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