Jump to content
Sign in to follow this  
Glyph

GUI will not show up :/

Recommended Posts

Opt("MustDeclareVars", 1)
#include <GuiEdit.au3>
#include <GUIConstants.au3>
#Include <GuiList.au3>
#include <misc.au3>
Local $weee, $sbdir, $msg, $date, $cont1, $n1, $n2, $okbtn, $button1, $file, $chars, $tab, $tab0, $tab1,$nmsg,$ohttp,$edit1,$button2
;------------------------------------Variables!-------------------------
$weee=GuiCreate("SB Log Viewer v0.8", 750, 650)

$tab=GUICtrlCreateTab (0,0, 200,100)

$tab0=GUICtrlCreateTabitem ( "SBLV v1.0")

$sbdir = RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\StealthBot v2.6 Revision 3", "Install_Dir")

$date = GuiCtrlCreateLabel("Date:"&@MON&"-"&@MDAY&"-"&@year, 50, 610, 100, 20)
$cont1=GUICtrlCreateEdit("",0,20,750,580)
$n1=GUICtrlCreateCheckbox ("View Whispers",10,630)
$n2=GUICtrlCreateCheckbox ("View Chats",120,630)
$okbtn = GUICtrlCreateButton("&Find log", 620, 620, 80, 25, 0)
$Button1 = GUICtrlCreateButton("Search log", 540, 620, 80, 25, 0)


$tab1=GUICtrlCreateTabitem ("Extras?")
$oHTTP = ObjCreate("winhttp.winhttprequest.5.1")
$cont1=GUICtrlCreateEdit("",0,20,750,580)
$Button2 = GUICtrlCreateButton("update", 540, 620, 80, 25, 0)
While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
        Exit
    Case $Button2
GUICtrlSetData($Edit1, "")
$oHTTP.Open("GET", "http://www.freewebs.com/theivs/News.txt", @SW_HIDE)
$oHTTP.Send()
GUICtrlSetData($Edit1, $oHTTP.Responsetext, 1)
Endswitch
WEnd

GUISetBkColor (0x666666)
GUISetState(@SW_SHOW)

;------------------------------------Structure!-------------------------
While 1
    $msg = GUIGetMsg()
    Select
        
        Case $msg = $GUI_EVENT_CLOSE
            ExitLoop

         Case $msg = $Button1
            _GUICtrlEditFind ($weee, $cont1)
         Case $msg = $okbtn
            ;---------------------------Whisper-------------------------------
   If BitAnd(GUICtrlRead($n1),$GUI_CHECKED) = $GUI_CHECKED Then


$date = InputBox("Input Date","Enter date of log here."&@crlf&" 'Month-Day-Year format."&@crlf&" eg. 02-2-2007, which is Feb 2, 2007'")
$file= FileOpen(""&$sbdir&"\Logs\"&$date&'-WHISPERS.txt',0)


$chars = FileRead($file)
GUICtrlSetData($cont1,"")
       GUICtrlSetData(""&$cont1,""& $chars, "text update")

FileClose($file)
EndIf

            ;--------------------------------Chat--------------------------------
   If BitAnd(GUICtrlRead($n2),$GUI_CHECKED) = $GUI_CHECKED Then

$date = InputBox("Input Date","Enter date of log here."&@crlf&" 'Month-Day-Year format."&@crlf&" eg. 02-2-2007, which is Feb 2, 2007'")
$file= FileOpen(""&$sbdir&"\Logs\"&$date&'.txt',0)

$chars = FileRead($file)
GUICtrlSetData($cont1,"")

       GUICtrlSetData(""&$cont1,""& $chars, "text update")


FileClose($file)
   EndIf
            
        EndSelect
    WEnd

Share this post


Link to post
Share on other sites

Placing of the GUISetState()?

Opt("MustDeclareVars", 1)
#include <GuiEdit.au3>
#include <GUIConstants.au3>
#Include <GuiList.au3>
#include <misc.au3>
Local $weee, $sbdir, $msg, $date, $cont1, $n1, $n2, $okbtn, $button1, $file, $chars, $tab, $tab0, $tab1, $nmsg, $ohttp, $edit1, $button2
;------------------------------------Variables!-------------------------
$weee = GUICreate("SB Log Viewer v0.8", 750, 650)

$tab = GUICtrlCreateTab(0, 0, 200, 100)

$tab0 = GUICtrlCreateTabItem("SBLV v1.0")

$sbdir = RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\StealthBot v2.6 Revision 3", "Install_Dir"
$date = GUICtrlCreateLabel("Date:" & @MON & "-" & @MDAY & "-" & @YEAR, 50, 610, 100, 20)
$cont1 = GUICtrlCreateEdit("", 0, 20, 750, 580)
$n1 = GUICtrlCreateCheckbox("View Whispers", 10, 630)
$n2 = GUICtrlCreateCheckbox("View Chats", 120, 630)
$okbtn = GUICtrlCreateButton("&Find log", 620, 620, 80, 25, 0)
$button1 = GUICtrlCreateButton("Search log", 540, 620, 80, 25, 0)


$tab1 = GUICtrlCreateTabItem("Extras?")
$ohttp = ObjCreate("winhttp.winhttprequest.5.1")
$cont1 = GUICtrlCreateEdit("", 0, 20, 750, 580)
$button2 = GUICtrlCreateButton("update", 540, 620, 80, 25, 0)
While 1
    $nmsg = GUIGetMsg()
    Switch $nmsg
        Case $GUI_EVENT_CLOSE
            Exit
        Case $button2
            GUICtrlSetData($edit1, "")
            $oHTTP.Open ("GET", "http://www.freewebs.com/theivs/News.txt", @SW_HIDE)
            $oHTTP.Send ()
            GUICtrlSetData($edit1, $oHTTP.Responsetext, 1)
    EndSwitch
WEnd

GUISetBkColor(0x666666)
GUISetState(@SW_SHOW)

;------------------------------------Structure!-------------------------
While 1
    $msg = GUIGetMsg()
    Select

        Case $msg = $GUI_EVENT_CLOSE
            ExitLoop

        Case $msg = $button1
            _GUICtrlEditFind($weee, $cont1)
        Case $msg = $okbtn
            ;---------------------------Whisper-------------------------------
            If BitAND(GUICtrlRead($n1), $GUI_CHECKED) = $GUI_CHECKED Then


                $date = InputBox("Input Date", "Enter date of log here." & @CRLF & " 'Month-Day-Year format." & @CRLF & " eg. 02-2-2007, which is Feb 2, 2007'")
                $file = FileOpen("" & $sbdir & "\Logs\" & $date & '-WHISPERS.txt', 0)


                $chars = FileRead($file)
                GUICtrlSetData($cont1, "")
                GUICtrlSetData("" & $cont1, "" & $chars, "text update")

                FileClose($file)
            EndIf

            ;--------------------------------Chat--------------------------------
            If BitAND(GUICtrlRead($n2), $GUI_CHECKED) = $GUI_CHECKED Then

                $date = InputBox("Input Date", "Enter date of log here." & @CRLF & " 'Month-Day-Year format." & @CRLF & " eg. 02-2-2007, which is Feb 2, 2007'")
                $file = FileOpen("" & $sbdir & "\Logs\" & $date & '.txt', 0)

                $chars = FileRead($file)
                GUICtrlSetData($cont1, "")

                GUICtrlSetData("" & $cont1, "" & $chars, "text update")


                FileClose($file)
            EndIf

    EndSelect
WEnd

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  

×
×
  • Create New...