Sign in to follow this  
Followers 0
Krillr

Tab and Button problem

2 posts in this topic

#1 ·  Posted (edited)

Ok, im making this bot, but i got thos problem. The Code is kinda long so i wont post it unless requested. Just gonna post some of the code here, because thats the part i got a problem with :-)

#include <ButtonConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <TabConstants.au3>
#include <WindowsConstants.au3>
Opt('MustDeclareVars', 0)

Example()

Func Example()
    Local $tab, $tab0, $tab0OK, $tab0input
    Local $tab1, $tab1combo, $tab1OK
    Local $tab2, $tab2OK, $msg
    
GUICreate("Krilleres Spam'o Matic", 420, 225, 194, 127)
GUISetFont(9, 400, 0, "MS Sans Serif")
GUISetBkColor(0xFFFFFF)
$tab = GUICtrlCreateTab(2, 2, 416, 220)
GUICtrlSetResizing(-1, $GUI_DOCKWIDTH+$GUI_DOCKHEIGHT)

; Frontpage
$tab0 = GUICtrlCreateTabItem("Frontpage")
$Label1 = GUICtrlCreateLabel("Hello. Welcome to my Spam Bot. Please read the ReadMe file before use!", 32, 80, 353, 18)
GUICtrlSetFont(-1, 8, 400, 0, "Arial")
$Button1 = GUICtrlCreateButton("ReadMe", 176, 152, 75, 25, 0)
GUICtrlSetFont(-1, 8, 400, 0, "Arial")
$Label2 = GUICtrlCreateLabel("Just click one of th tabs and spam on!", 120, 120, 185, 18)
GUICtrlSetFont(-1, 8, 400, 0, "Arial")

; Yell
$tab1 = GUICtrlCreateTabItem("Yell")
$Label3 = GUICtrlCreateLabel("What do you want to spam?", 16, 72, 140, 18)
GUICtrlSetFont(-1, 8, 400, 0, "Arial")
$Label4 = GUICtrlCreateLabel("Time Between spams?", 16, 112, 114, 18)
GUICtrlSetFont(-1, 8, 400, 0, "Arial")
$Input1 = GUICtrlCreateInput("", 176, 72, 209, 22)
GUICtrlSetFont(-1, 8, 400, 0, "Arial")
$Input2 = GUICtrlCreateInput("", 176, 112, 209, 22)
GUICtrlSetFont(-1, 8, 400, 0, "Arial")
$Button2 = GUICtrlCreateButton("Spam !", 136, 168, 123, 25, 0)
GUICtrlSetFont(-1, 8, 400, 0, "Arial")

; Whisper
$tab2 = GUICtrlCreateTabItem("Whisper")
$Label5 = GUICtrlCreateLabel("What do you want to spam?", 23, 73, 140, 18)
GUICtrlSetFont(-1, 8, 400, 0, "Arial")
$Label6 = GUICtrlCreateLabel("Time Between spams?", 23, 115, 114, 18)
GUICtrlSetFont(-1, 8, 400, 0, "Arial")
$Input3 = GUICtrlCreateInput("", 181, 67, 209, 22)
GUICtrlSetFont(-1, 8, 400, 0, "Arial")
$Input4 = GUICtrlCreateInput("", 181, 110, 209, 22)
GUICtrlSetFont(-1, 8, 400, 0, "Arial")
$Button3 = GUICtrlCreateButton("Spam !", 147, 161, 123, 25, 0)
GUICtrlSetFont(-1, 8, 400, 0, "Arial")

; Emote
$Tab3 = GUICtrlCreateTabItem("Emote")
$Label7 = GUICtrlCreateLabel("Time Between spams?", 24, 110, 111, 17)
$Label11 = GUICtrlCreateLabel("What do you want to spam?", 25, 69, 137, 17)
$Input5 = GUICtrlCreateInput("", 181, 67, 209, 21)
$Input6 = GUICtrlCreateInput("", 181, 107, 209, 21)
$Button4 = GUICtrlCreateButton("Spam !", 137, 161, 123, 25, 0)

; General
$Tab4 = GUICtrlCreateTabItem("General")
$Label8 = GUICtrlCreateLabel("Time Between spams?", 24, 114, 111, 17)
$Label12 = GUICtrlCreateLabel("What do you want to spam?", 27, 75, 137, 17)
$Input7 = GUICtrlCreateInput("", 181, 71, 209, 21)
$Input8 = GUICtrlCreateInput("", 181, 110, 209, 21)
$Button5 = GUICtrlCreateButton("Spam !", 145, 168, 123, 25, 0)

; Trade
$Tab5 = GUICtrlCreateTabItem("Trade")
$Label9 = GUICtrlCreateLabel("Time Between spams?", 18, 116, 111, 17)
$Label13 = GUICtrlCreateLabel("What do you want to spam?", 19, 69, 137, 17)
$Input9 = GUICtrlCreateInput("", 181, 67, 209, 21)
$Input10 = GUICtrlCreateInput("", 181, 112, 209, 21)
$Button6 = GUICtrlCreateButton("Spam !", 144, 161, 123, 25, 0)

; Normal
$Tab6 = GUICtrlCreateTabItem("Normal")
$Label10 = GUICtrlCreateLabel("Time Between spams?", 29, 118, 111, 17)
$Label14 = GUICtrlCreateLabel("What do you want to spam?", 25, 77, 137, 17)
$Input11 = GUICtrlCreateInput("", 181, 79, 209, 21)
$Input12 = GUICtrlCreateInput("", 181, 115, 209, 21)
$Button7 = GUICtrlCreateButton("Spam !", 145, 171, 123, 25, 0)

; Save Load
$Tab7 = GUICtrlCreateTabItem("Save/Load")
GUICtrlCreateTabItem("")
GUISetState()

While 2
    

        $MSG = GUIGetMsg()
        Select
            Case $MSG = $GUI_EVENT_CLOSE
                ExitLoop
            Case $MSG = $Button1
                Run("Notepad.exe")
WEnd            

          

EndFunc

I made some buttons in some of the tabs, but i cant get this to work :S When i open the program it tellse me: Error: "Wend" statement with no matching "While" statement. Which is weird because its in the code :S You should see it on the example i made. Am i doing something wrong or? Would really be nice if something happened when i pressed the buttons :) And tbh the reason i didnt want to shot the source code was because im making a bot and i dont know what you guys think about that :-) But i hope its ok

Edited by Krillr

Share this post


Link to post
Share on other sites



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 account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0