Jump to content

_IE problemm


 Share

Recommended Posts

Hello there.

I have 1 more problem with my Programm.... I am trying to write Bot for 1 game but................

I need to understand how to add funktions to Buttons.... Plz someone explain me how to work with GUI :)

For Exampel i have this code :

#include <GUIConstants.au3>


$Form1_1 = GUICreate("Metin2 Bot", 493, 229, 275, 270)
GUISetIcon("C:\Programme\Metin2_Germany\metin2.exe")
$Pic1 = GUICtrlCreatePic("C:\Programme\Metin2_Germany\patchskin\main.bmp", 0, 0, 492, 228, $WS_CLIPSIBLINGS)
$Button2 = GUICtrlCreateButton("Stop Bot", 392, 56, 75, 25, 0)
$Button3 = GUICtrlCreateButton("Info", 392, 96, 75, 25, 0)
$Button4 = GUICtrlCreateButton("Speed Hack", 392, 136, 75, 25, 0)
$Button5 = GUICtrlCreateButton("Exit", 392, 176, 75, 25, 0)
$Button1 = GUICtrlCreateButton("Start Bot", 392, 16, 75, 25, 0)

So how can i make so, when i push Exit it ll close Programm or when i push info it will open MsgBox with info ??? How ??? plz explain... I am noob in this things and i realy wanna know how to do this.

Now to my problem....

There you go :

#include <GUIConstants.au3>
#include <IE.au3>

#Region ### START Koda GUI section ### Form=c:\programme\metin2_germany\patchskin\metin2 form.kxf
$Form1_1 = GUICreate("Metin2 Bot", 493, 229, 275, 270)
GUISetIcon("C:\Programme\Metin2_Germany\metin2.exe")
$Pic1 = GUICtrlCreatePic("C:\Programme\Metin2_Germany\patchskin\main.bmp", 0, 0, 492, 228, $WS_CLIPSIBLINGS)
$Button2 = GUICtrlCreateButton("Stop Bot", 392, 56, 75, 25, 0)
$Button3 = GUICtrlCreateButton("Info", 392, 96, 75, 25, 0)
$Button4 = GUICtrlCreateButton("Speed Hack", 392, 136, 75, 25, 0)
$Button5 = GUICtrlCreateButton("Exit", 392, 176, 75, 25, 0)
$Button1 = GUICtrlCreateButton("Start Bot", 392, 16, 75, 25, 0)
$Progress1 = GUICtrlCreateProgress(16, 192, 350, 17)
$Button6 = GUICtrlCreateButton("(Not allowed)", 24, 32, 127, 40, $BS_BITMAP)
GUICtrlSetImage(-1, "C:\Programme\Metin2_Germany\patchskin\btn_startgame_fs.bmp", 0)
$Button7 = GUICtrlCreateButton("(Not allowed)", 24, 96, 127, 25, $BS_BITMAP)
GUICtrlSetImage(-1, "C:\Programme\Metin2_Germany\patchskin\btn_settings_up.bmp", 0)
$Button8 = GUICtrlCreateButton("(Not allowed)", 24, 144, 127, 25, $BS_BITMAP)
GUICtrlSetImage(-1, "C:\Programme\Metin2_Germany\patchskin\btn_quit_fs.bmp", 0)
$Button9 = GUICtrlCreateButton("(Not allowed)", 224, 96, 127, 25, BitOR($BS_BITMAP,$WS_BORDER))
GUICtrlSetImage(-1, "C:\Programme\Metin2_Germany\patchskin\btn_newaccount_up.bmp", 0)
$Button10 = GUICtrlCreateButton("(Not allowed)", 224, 144, 127, 25, $BS_BITMAP)
GUICtrlSetImage(-1, "C:\Programme\Metin2_Germany\patchskin\btn_idpwd_up.bmp", 0)
$Label1 = GUICtrlCreateLabel("Metin2 Bot by ..::DeMoN::..", 184, 16, 185, 20)
GUICtrlSetFont(-1, 10, 800, 0, "MS Sans Serif")
GUICtrlSetColor(-1, 0x008000)
GUICtrlSetBkColor(-1, 0x000000)
$Label2 = GUICtrlCreateLabel("Have Fun xD!!!", 232, 48, 90, 17)
GUICtrlSetFont(-1, 8, 800, 0, "MS Sans Serif")
GUICtrlSetColor(-1, 0x008000)
GUICtrlSetBkColor(-1, 0x000000)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###

While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $GUI_EVENT_CLOSE
            Exit

        Case $Button9
    EndSwitch
WEnd

Func OpenAcc() 
If $Button10 = 1 Then
    _IECreate("www.metin2.de")
EndIf
EndFunc

Func OpenAcc() <----- It wont work for me.... It doesnt open this page that i want... but why ?!?!?!? I pushing at Button but it dont work

If $Button10 = 1 Then

_IECreate("www.metin2.de")

EndIf

EndFunc

So i need someone who can explain me how to work with GUI and how to add Funktions ( working funktions ) to buttons etc.

Thx.

Waiting for help ^_^

Link to comment
Share on other sites

Something like this?

#include <GUIConstants.au3>
#include <IE.au3>

#Region ### START Koda GUI section ### Form=c:\programme\metin2_germany\patchskin\metin2 form.kxf
$Form1_1 = GUICreate("Metin2 Bot", 493, 229, 275, 270)
GUISetIcon("C:\Programme\Metin2_Germany\metin2.exe")
$Pic1 = GUICtrlCreatePic("C:\Programme\Metin2_Germany\patchskin\main.bmp", 0, 0, 492, 228, $WS_CLIPSIBLINGS)
$Button2 = GUICtrlCreateButton("Stop Bot", 392, 56, 75, 25, 0)
$Button3 = GUICtrlCreateButton("Info", 392, 96, 75, 25, 0)
$Button4 = GUICtrlCreateButton("Speed Hack", 392, 136, 75, 25, 0)
$Button5 = GUICtrlCreateButton("Exit", 392, 176, 75, 25, 0)
$Button1 = GUICtrlCreateButton("Start Bot", 392, 16, 75, 25, 0)
$Progress1 = GUICtrlCreateProgress(16, 192, 350, 17)
$Button6 = GUICtrlCreateButton("(Not allowed)", 24, 32, 127, 40, $BS_BITMAP)
GUICtrlSetImage(-1, "C:\Programme\Metin2_Germany\patchskin\btn_startgame_fs.bmp", 0)
$Button7 = GUICtrlCreateButton("(Not allowed)", 24, 96, 127, 25, $BS_BITMAP)
GUICtrlSetImage(-1, "C:\Programme\Metin2_Germany\patchskin\btn_settings_up.bmp", 0)
$Button8 = GUICtrlCreateButton("(Not allowed)", 24, 144, 127, 25, $BS_BITMAP)
GUICtrlSetImage(-1, "C:\Programme\Metin2_Germany\patchskin\btn_quit_fs.bmp", 0)
$Button9 = GUICtrlCreateButton("(Not allowed)", 224, 96, 127, 25, BitOR($BS_BITMAP,$WS_BORDER))
GUICtrlSetImage(-1, "C:\Programme\Metin2_Germany\patchskin\btn_newaccount_up.bmp", 0)
$Button10 = GUICtrlCreateButton("(Not allowed)", 224, 144, 127, 25, $BS_BITMAP)
GUICtrlSetImage(-1, "C:\Programme\Metin2_Germany\patchskin\btn_idpwd_up.bmp", 0)
$Label1 = GUICtrlCreateLabel("Metin2 Bot by ..::DeMoN::..", 184, 16, 185, 20)
GUICtrlSetFont(-1, 10, 800, 0, "MS Sans Serif")
GUICtrlSetColor(-1, 0x008000)
GUICtrlSetBkColor(-1, 0x000000)
$Label2 = GUICtrlCreateLabel("Have Fun xD!!!", 232, 48, 90, 17)
GUICtrlSetFont(-1, 8, 800, 0, "MS Sans Serif")
GUICtrlSetColor(-1, 0x008000)
GUICtrlSetBkColor(-1, 0x000000)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###

While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $GUI_EVENT_CLOSE
            Exit

        Case $nMsg = $Button10
                OpenAcc()
    EndSwitch
WEnd

Func OpenAcc() 
    _IECreate("www.metin2.de")
EndFunc
Edited by Forsaken
Link to comment
Share on other sites

And how it ll not on what button i pushing ???? It should know when i push Button10 only it should open....

SO ? When i pushing Button10 it should open :) But i cant see any code there that do it :)

OH>> I SEE IT NOW ^_^ THX

Edited by Demon777
Link to comment
Share on other sites

So... i do like u showed me but now when i open programm no Button works and GUI stopping work !

It showing this : --> IE.au3 V2.3-1 Error from function _IECreate (Browser Object Creation Failed)

Edited by Demon777
Link to comment
Share on other sites

So... i do like u showed me but now when i open programm no Button works and GUI stopping work !

It showing this : --> IE.au3 V2.3-1 Error from function _IECreate (Browser Object Creation Failed)

Usually means that you have a foobar iexplore.exe process on your system... kill all iexplore.exe processes, logout and back in or reboot.

Dale

Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl

MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model

Automate input type=file (Related)

Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded  Better Better?

IE.au3 issues with Vista - Workarounds

SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y

Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead?

Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble

Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...