You last visited: Today at 08:27
Advertisement
[AutoIT] Problem mit X Knopf
Discussion on [AutoIT] Problem mit X Knopf within the AutoIt forum part of the Coders Den category.
08/15/2010, 19:04
#1
elite*gold: 0
Join Date: Nov 2009
Posts: 62
Received Thanks: 10
[AutoIT] Problem mit X Knopf
Hallo liebe epvp Community
Ich habe folgendes Problem. Undzwar habe ich mir einen Spambot geschrieben der mit der F1 Taste startet, F2 pausiert und mit F3 den Bot beendet. Nun is das Problem aber das ich das Program nicht mehr mit dem rotem X Knopf oben am rechten Fensterrand nicht mehr schließen kann.
Wenn ich nun folgenden Code eingebe:
Quote:
While 1
$msg = GUIGetMsg()
Switch $msg
Case $GUI_EVENT_CLOSE
Exit
EndSwitch
WEnd
dann klappt zwar der Knopf oben Rechts und F3 Taste aber nicht mehr F1 und F2 zum starten und Pausieren des Bots
Mein Script sieht wie folgt aus:
Code:
#include <ButtonConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#include <StaticConstants.au3>
#Region ### START Koda GUI section ### Form=
$Form1_1 = GUICreate("Spammbot by Crusted Core und KingPin", 444, 504, 302, 205)
$Fenster1 = GUICtrlCreateEdit("Bitte ausfüllen", 8, 8, 209, 137)
$Fenster2 = GUICtrlCreateEdit("Bitte ausfüllen", 224, 8, 209, 137)
$Fenster3 = GUICtrlCreateEdit("Bitte ausfüllen", 8, 184, 209, 137)
$Fenster4 = GUICtrlCreateEdit("Bitte ausfüllen", 224, 184, 209, 137)
$Label1 = GUICtrlCreateLabel("1", 8, 152, 68, 20)
GUICtrlSetFont(-1, 10, 800, 0, "MS Sans Serif")
$Label2 = GUICtrlCreateLabel("2", 224, 152, 68, 20)
GUICtrlSetFont(-1, 10, 800, 0, "MS Sans Serif")
$Label3 = GUICtrlCreateLabel("3", 8, 328, 68, 20)
GUICtrlSetFont(-1, 10, 800, 0, "MS Sans Serif")
$Label4 = GUICtrlCreateLabel("4", 224, 328, 68, 20)
GUICtrlSetFont(-1, 10, 800, 0, "MS Sans Serif")
$Label5 = GUICtrlCreateLabel("Bot Funktionen:", 8, 368, 123, 22)
GUICtrlSetFont(-1, 10, 800, 0, "Arial Black")
$Zeit1 = GUICtrlCreateEdit("", 128, 152, 89, 25, BitOR($ES_AUTOVSCROLL,$ES_AUTOHSCROLL,$ES_WANTRETURN))
GUICtrlSetData(-1, "1000")
$Zeit2 = GUICtrlCreateEdit("", 344, 152, 89, 25, BitOR($ES_AUTOVSCROLL,$ES_AUTOHSCROLL,$ES_WANTRETURN))
GUICtrlSetData(-1, "1000")
$Zeit3 = GUICtrlCreateEdit("", 128, 328, 89, 25, BitOR($ES_AUTOVSCROLL,$ES_AUTOHSCROLL,$ES_WANTRETURN))
GUICtrlSetData(-1, "1000")
$Zeit4 = GUICtrlCreateEdit("", 344, 328, 89, 25, BitOR($ES_AUTOVSCROLL,$ES_AUTOHSCROLL,$ES_WANTRETURN))
GUICtrlSetData(-1, "1000")
$Label6 = GUICtrlCreateLabel("© Crusted Core u. KingPin", 312, 480, 125, 17)
$Label7 = GUICtrlCreateLabel("F1 = Bot Starten", 8, 392, 113, 20)
GUICtrlSetFont(-1, 10, 800, 0, "MS Sans Serif")
$Label8 = GUICtrlCreateLabel("F2 = Bot Pausieren", 8, 408, 134, 20)
GUICtrlSetFont(-1, 10, 800, 0, "MS Sans Serif")
$Label9 = GUICtrlCreateLabel("F3 = Bot Beenden", 8, 424, 126, 20)
GUICtrlSetFont(-1, 10, 800, 0, "MS Sans Serif")
$Label10 = GUICtrlCreateLabel("Anleitung:", 280, 368, 51, 17)
$Label11 = GUICtrlCreateLabel("Chatfenster anklicken und F1 drücken", 216, 392, 185, 17)
$Label12 = GUICtrlCreateLabel("Zeit in Mili-sek.", 56, 160, 70, 17)
$Label13 = GUICtrlCreateLabel("Zeit in Mili-sek.", 272, 160, 70, 17)
$Label14 = GUICtrlCreateLabel("Zeit in Mili-sek.", 56, 336, 70, 17)
$Label15 = GUICtrlCreateLabel("Zeit in Mili-sek.", 272, 336, 70, 17)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###
HotKeySet("{F1}", "Start")
HotKeySet("{F2}", "Pause")
HotKeySet("{F3}", "Ende")
Global $Aktivieren = 0
While 1
If $Aktivieren = 1 Then
Send (GuiCtrlRead($Fenster1))
Sleep(GuiCtrlRead($Zeit1))
Send ("{Enter}")
Send (GuiCtrlRead($Fenster2))
Sleep(GuiCtrlRead($Zeit2))
Send ("{Enter}")
Send (GuiCtrlRead($Fenster3))
Sleep(GuiCtrlRead($Zeit3))
Send ("{Enter}")
Send (GuiCtrlRead($Fenster4))
Sleep(GuiCtrlRead($Zeit4))
Send ("{Enter}")
EndIf
Wend
Func Start()
$Aktivieren = 1
EndFunc
Func Pause()
$Aktivieren = 0
EndFunc
Func Ende()
Exit
EndFunc
Das ganze ist mit Autoit geschrieben.
MfG kthxbb
08/15/2010, 19:43
#2
elite*gold: 0
Join Date: Dec 2009
Posts: 343
Received Thanks: 74
Ty reagiert einfach nicht mehr auf das Event das ausgelöst wird.
Bin sowieso kein AutoIT fan kann dir jetzt also nur so sagen: "entweder - oder" sry
08/15/2010, 20:08
#3
elite*gold: 0
Join Date: Nov 2009
Posts: 62
Received Thanks: 10
Also gibt es eine möglichkeit dieses Problem zu lösen?? bitte um hilfe
08/15/2010, 20:11
#4
elite*gold: 0
Join Date: Mar 2009
Posts: 2,317
Received Thanks: 1,255
PHP Code:
#include <ButtonConstants.au3> #include <EditConstants.au3> #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #include <StaticConstants.au3> #Region ### START Koda GUI section ### Form= $Form1_1 = GUICreate ( "Spammbot by Crusted Core und KingPin" , 444 , 504 , 302 , 205 ) $Fenster1 = GUICtrlCreateEdit ( "Bitte ausfüllen" , 8 , 8 , 209 , 137 ) $Fenster2 = GUICtrlCreateEdit ( "Bitte ausfüllen" , 224 , 8 , 209 , 137 ) $Fenster3 = GUICtrlCreateEdit ( "Bitte ausfüllen" , 8 , 184 , 209 , 137 ) $Fenster4 = GUICtrlCreateEdit ( "Bitte ausfüllen" , 224 , 184 , 209 , 137 ) $Label1 = GUICtrlCreateLabel ( "1" , 8 , 152 , 68 , 20 ) GUICtrlSetFont (- 1 , 10 , 800 , 0 , "MS Sans Serif" ) $Label2 = GUICtrlCreateLabel ( "2" , 224 , 152 , 68 , 20 ) GUICtrlSetFont (- 1 , 10 , 800 , 0 , "MS Sans Serif" ) $Label3 = GUICtrlCreateLabel ( "3" , 8 , 328 , 68 , 20 ) GUICtrlSetFont (- 1 , 10 , 800 , 0 , "MS Sans Serif" ) $Label4 = GUICtrlCreateLabel ( "4" , 224 , 328 , 68 , 20 ) GUICtrlSetFont (- 1 , 10 , 800 , 0 , "MS Sans Serif" ) $Label5 = GUICtrlCreateLabel ( "Bot Funktionen:" , 8 , 368 , 123 , 22 ) GUICtrlSetFont (- 1 , 10 , 800 , 0 , "Arial Black" ) $Zeit1 = GUICtrlCreateEdit ( "" , 128 , 152 , 89 , 25 , BitOR ( $ES_AUTOVSCROLL , $ES_AUTOHSCROLL , $ES_WANTRETURN )) GUICtrlSetData (- 1 , "1000" ) $Zeit2 = GUICtrlCreateEdit ( "" , 344 , 152 , 89 , 25 , BitOR ( $ES_AUTOVSCROLL , $ES_AUTOHSCROLL , $ES_WANTRETURN )) GUICtrlSetData (- 1 , "1000" ) $Zeit3 = GUICtrlCreateEdit ( "" , 128 , 328 , 89 , 25 , BitOR ( $ES_AUTOVSCROLL , $ES_AUTOHSCROLL , $ES_WANTRETURN )) GUICtrlSetData (- 1 , "1000" ) $Zeit4 = GUICtrlCreateEdit ( "" , 344 , 328 , 89 , 25 , BitOR ( $ES_AUTOVSCROLL , $ES_AUTOHSCROLL , $ES_WANTRETURN )) GUICtrlSetData (- 1 , "1000" ) $Label6 = GUICtrlCreateLabel ( "© Crusted Core u. KingPin" , 312 , 480 , 125 , 17 ) $Label7 = GUICtrlCreateLabel ( "F1 = Bot Starten" , 8 , 392 , 113 , 20 ) GUICtrlSetFont (- 1 , 10 , 800 , 0 , "MS Sans Serif" ) $Label8 = GUICtrlCreateLabel ( "F2 = Bot Pausieren" , 8 , 408 , 134 , 20 ) GUICtrlSetFont (- 1 , 10 , 800 , 0 , "MS Sans Serif" ) $Label9 = GUICtrlCreateLabel ( "F3 = Bot Beenden" , 8 , 424 , 126 , 20 ) GUICtrlSetFont (- 1 , 10 , 800 , 0 , "MS Sans Serif" ) $Label10 = GUICtrlCreateLabel ( "Anleitung:" , 280 , 368 , 51 , 17 ) $Label11 = GUICtrlCreateLabel ( "Chatfenster anklicken und F1 drücken" , 216 , 392 , 185 , 17 ) $Label12 = GUICtrlCreateLabel ( "Zeit in Mili-sek." , 56 , 160 , 70 , 17 ) $Label13 = GUICtrlCreateLabel ( "Zeit in Mili-sek." , 272 , 160 , 70 , 17 ) $Label14 = GUICtrlCreateLabel ( "Zeit in Mili-sek." , 56 , 336 , 70 , 17 ) $Label15 = GUICtrlCreateLabel ( "Zeit in Mili-sek." , 272 , 336 , 70 , 17 ) GUISetState (@ SW_SHOW ) #EndRegion ### END Koda GUI section ### HotKeySet ( "{F1}" , "Start" ) HotKeySet ( "{F2}" , "Pause" ) HotKeySet ( "{F3}" , "Ende" ) Global $Aktivieren = 0 While 1 $msg = GUIGetMsg () Switch $msg Case $GUI_EVENT_CLOSE Exit EndSwitch starter () WEnd Func starter () If $Aktivieren = 1 Then Send ( GuiCtrlRead ( $Fenster1 )) Sleep ( GuiCtrlRead ( $Zeit1 )) Send ( "{Enter}" ) Send ( GuiCtrlRead ( $Fenster2 )) Sleep ( GuiCtrlRead ( $Zeit2 )) Send ( "{Enter}" ) Send ( GuiCtrlRead ( $Fenster3 )) Sleep ( GuiCtrlRead ( $Zeit3 )) Send ( "{Enter}" ) Send ( GuiCtrlRead ( $Fenster4 )) Sleep ( GuiCtrlRead ( $Zeit4 )) Send ( "{Enter}" ) EndIf EndFunc Func Start () $Aktivieren = 1 EndFunc Func Pause () $Aktivieren = 0 EndFunc Func Ende () Exit EndFunc
08/15/2010, 20:40
#5
elite*gold: 0
Join Date: Nov 2009
Posts: 62
Received Thanks: 10
omg vielen vielen dank und mehr war das auch nicht :/
ich hätte da aber noch eine kleine frage bezüglich der Labels.
nehmen wir an ich packe nun im hintergrund ein bild dann habe ich das prob das wenn ich ein Label erstelle im hintergrund der schrift noch farbe ist. ich würde das aber gerne so gestalten das nur die schrift des Labels zu sehen ist.
08/15/2010, 21:31
#6
elite*gold: 0
Join Date: Mar 2009
Posts: 2,317
Received Thanks: 1,255
in koda> rechtsklick auf die input-steuerelement-"in vordergrind rücken"
€ahh nee...
falsch verstanden..
08/15/2010, 21:39
#7
elite*gold: 0
Join Date: Nov 2009
Posts: 62
Received Thanks: 10
hmpf also ich meinte das so
wenn ich zb. diesen Label hier benutze
Code:
$Label11 = GUICtrlCreateLabel("Chatfenster anklicken und F1 drücken", 216, 392, 185, 17)
dann kommt ja auf meinen gui fenster der text "Chatfenster anklicken und F1 drücken" das problem ist aber das hinter dem text ein grauer balken ist den ich gerne transparent haben möchte.
08/15/2010, 21:45
#8
elite*gold: 116
Join Date: Oct 2007
Posts: 677
Received Thanks: 248
Dann mach doch auch die Hintergrundfarbe des GUIs grau
Ist nunmal so, dass dort ein grauer Streifen ist.
Und ich finds langsam echt nervend, dass ihr nicht EINMAL google benutzen könnt. da findest du das nämlich zu 100%.
Ein wenig Eigenintiative bitte.
08/15/2010, 21:56
#9
elite*gold: 0
Join Date: Nov 2009
Posts: 62
Received Thanks: 10
also....
wenn ich hier frage und dieses forum zum fragen da ist und ich schon in google gesucht habe dann ist es ja wohl erlaubt hier mal zu fragen.
und diesen streifen inna anderen farbe zu gestalten bringt wenig denn ich habe ein bild was ich im hintergrund haben möchte und wenn dort so ein grauer balken ist dann find ich das net so dolle.
08/15/2010, 22:35
#10
elite*gold: 0
Join Date: Mar 2009
Posts: 2,317
Received Thanks: 1,255
Quote:
Originally Posted by
kthxbb
also....
wenn ich hier frage und dieses forum zum fragen da ist und ich schon in google gesucht habe dann ist es ja wohl erlaubt hier mal zu fragen.
und diesen streifen inna anderen farbe zu gestalten bringt wenig denn ich habe ein bild was ich im hintergrund haben möchte und wenn dort so ein grauer balken ist dann find ich das net so dolle.
hättest du es wirklich, hättest du was gefunden...
ich hab gegooglt und nach 20sec schauen direkt was gefunden...
dann würde das so aussehen:
PHP Code:
#include <_Transinput.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
#Region ### START Koda GUI section ### Form=
$Form1 = GUICreate ( "Form1" , 625 , 443 , 192 , 124 )
$Pic1 = GUICtrlCreatePic ( "dein bild" , 40 , 60 , 481 , 317 , BitOR ( $SS_NOTIFY , $WS_GROUP , $WS_CLIPSIBLINGS ))
$label = GUICtrlCreateLabel ( "Label1" , 80 , 88 , 36 , 17 )
_TransInput_Create ( $label , 12 )
GUISetState (@ SW_SHOW )
#EndRegion ### END Koda GUI section ###
While 1
$nMsg = GUIGetMsg ()
Switch $nMsg
Case $GUI_EVENT_CLOSE
Exit
EndSwitch
WEnd
quelle:
Attached Files
_TransInput.rar
(712 Bytes, 2 views)
08/15/2010, 23:43
#11
elite*gold: 0
Join Date: Nov 2009
Posts: 62
Received Thanks: 10
Vielen dank.
Nur mit meinen Suchbegriffen bin ich nicht zum Ziel gekommen.
08/22/2010, 20:21
#12
elite*gold: 0
Join Date: Feb 2010
Posts: 388
Received Thanks: 111
Mein Bot runs
in/mit
opt GUISetOnEvent
solche Sorgen mit RedX gibts da nicht
und vieles andere ist auch besser so !
mfG
Similar Threads
Frage! Nach nem Knopf
12/12/2009 - WarRock - 3 Replies
leute bei nem hack von mir steht Cank + Roll jetzt wollte ich fragen wo der knopf Cank ist?
All times are GMT +1. The time now is 08:27 .