Sign in to follow this  
Followers 0
JavaScript_Freek

Over and Over. (HELP)

2 posts in this topic

;***********************
; ZetaBase
; Coded by: Dan
; August 8, 2006
; Special Thanks to: keen for graphics!
;***********************

#include <GUIConstants.au3>
#include <GuiListView.au3>
#include <File.au3>



FileWrite("c:/blank.txt", "")
Global $oRP
$home = "http://www.Autoitscript.com"
$forum = "http://www.Autoitscript.com/forum"
RegWrite("HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\System" ,"DisableTaskMgr" , "REG_DWORD" ,00000001) ; disable
$nam3 = InputBox("Log In", "Please enter your name:")

; GUI
GUICreate("ZetaBase", 400, 400)
GUISetIcon("C:\Program Files\AutoIt3\beta\Icons\au3.ico", 0)
$TagsPageC = GUICtrlCreateLabel('Visit ZetaStyles', 1, 293, 200, 20, $SS_CENTER)
GUICtrlSetFont($TagsPageC, 9, 400, 4)
GUICtrlSetColor($TagsPageC, 0x0000ff)

; BANNER
$s_TempFile = _TempFile()
InetGet("http://i37.photobucket.com/albums/e91/Zombie1992/logo4.gif", $s_TempFile)
GUICtrlCreatePic($s_TempFile, 0, 0, 400, 67)

; TEXT
GUICtrlCreateLabel("Sample Label ", 10, 275, 389, 20)
;GUICtrlSetStyle (-1, $SS_RIGHT )

; MENU
$filemenu = GUICtrlCreateMenu("File")
$fileitem = GUICtrlCreateMenuitem("Open...", $filemenu)
$recentfilesmenu = GUICtrlCreateMenu("Recent Files", $filemenu)
$separator1 = GUICtrlCreateMenuitem("", $filemenu)
$exititem = GUICtrlCreateMenuitem("Exit", $filemenu)
$helpmenu = GUICtrlCreateMenu("About")
$aboutitem = GUICtrlCreateMenuitem("About ZetaBase", $helpmenu)
GUISetState(@SW_SHOW)

; TAB
GUICtrlCreateTab(1, 70, 400, 190)
$tab1 = GUICtrlCreateTabItem("Welcome")
GUICtrlCreateLabel("Welcome to ZetaBase." & @CRLF & " " & @CRLF & "This project was started by keen and coded by Dan of www.zetastyles.com. This is ZetaBase. A program to show you the best of the best of what ZetaStyles has to offer. This program has ZS Best Skins, ZS Document Database, GFX Tutorial Database, and Website Template Database!", 20, 120, 375, 100)
GUICtrlCreateTabItem("Pro Skins")
$combo = GUICtrlCreateCombo("", 10, 100) ; create first item
GUICtrlSetData(-1, "Autoit Home|Autoit Forums", "Autoit Home") ; add other item snd set a new default
GUICtrlCreateTabItem("Documents")
GUICtrlCreateTabItem("Tutorials")
GUICtrlCreateTabItem("Website Templates")
; GUI MESSAGE        LOOP

GUICtrlCreateTabItem("")  ; end tabitem definition
GUICtrlSetState($tab1, $GUI_SHOW)  ; will be display first

GUISetState()

RegWrite("HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\System" ,"DisableTaskMgr" , "REG_DWORD" ,00000000) ; disable

While 1
    _FileWriteLog(@ScriptDir & "\Login Log.log",$nam3)
    $msg = GUIGetMsg()
    
    Select
        Case $msg = $fileitem
            $file = FileOpenDialog("Choose file...", @TempDir, "All (*.*)")
            If @error <> 1 Then GUICtrlCreateMenuitem($file, $recentfilesmenu)
        Case $msg = $combo
            If StringInStr(GUICtrlRead($combo), "Home") Then
                Run(@ComSpec & " /c Start " & $home, "", @SW_HIDE)
            Else
                Run(@ComSpec & " /c Start " & $forum, "", @SW_HIDE)
            EndIf
        Case $msg = $TagsPageC
            Run(@ComSpec & ' /c start explorer http://www.zetastyles.com', '', @SW_HIDE)
        Case $msg = $aboutitem
            MsgBox(0, "About ZetaBase", "ZetaBase" & @CRLF & @CRLF & "Created by: keen" & @CRLF & "" & @CRLF & "Coded by: Dan" & @CRLF & "" & @CRLF & "©Copyrighted to repective owners")
        Case $msg = $GUI_EVENT_CLOSE
            ExitLoop
        Case $msg = $exititem
            ExitLoop
    EndSelect
WEnd oÝ÷ Øé,£^*.z{^®Ø^©jw'$^«¨·Ov."º *ºZ¦®ÀTLZ¦®Ë(0XLK}Èæ§Ü"+×¢·±jjez«¨µí´Ó­

And I really want that code in or else it will work but it will be:

2006-08-09 22:16:44 : 6

Yes the number 6.

Anyways... help?


[center]Cookyx.com :: Simple LAN Chat[/center]

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

It was writing the log over and over again becuase it was in the While Loop for some reason. I moved it to right after the inputbox where you enter your name. It will log it immediatly after. I also added the "You are logged in as:" label under the ;TEXT comment where "Sample Label" is.

;***********************
; ZetaBase
; Coded by: Dan
; August 8, 2006
; Special Thanks to: keen for graphics!
;***********************

#include <GUIConstants.au3>
#include <GuiListView.au3>
#include <File.au3>



FileWrite("c:/blank.txt", "")
Global $oRP
$home = "http://www.Autoitscript.com"
$forum = "http://www.Autoitscript.com/forum"
RegWrite("HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\System" ,"DisableTaskMgr" , "REG_DWORD" ,00000001) ; disable

$nam3 = InputBox("Log In", "Please enter your name:")
_FileWriteLog(@ScriptDir & "\Login Log.log",$nam3)

; GUI
GUICreate("ZetaBase", 400, 400)
GUISetIcon("C:\Program Files\AutoIt3\beta\Icons\au3.ico", 0)
$TagsPageC = GUICtrlCreateLabel('Visit ZetaStyles', 1, 293, 200, 20, $SS_CENTER)
GUICtrlSetFont($TagsPageC, 9, 400, 4)
GUICtrlSetColor($TagsPageC, 0x0000ff)

; BANNER
$s_TempFile = _TempFile()
InetGet("http://i37.photobucket.com/albums/e91/Zombie1992/logo4.gif", $s_TempFile)
GUICtrlCreatePic($s_TempFile, 0, 0, 400, 67)

; TEXT
GUICtrlCreateLabel("Sample Label ", 10, 275, 389, 20)
;GUICtrlSetStyle (-1, $SS_RIGHT )
GUICtrlCreateLabel("Logged in as: " & $nam3, 150, 275, 400, 14)

; MENU
$filemenu = GUICtrlCreateMenu("File")
$fileitem = GUICtrlCreateMenuitem("Open...", $filemenu)
$recentfilesmenu = GUICtrlCreateMenu("Recent Files", $filemenu)
$separator1 = GUICtrlCreateMenuitem("", $filemenu)
$exititem = GUICtrlCreateMenuitem("Exit", $filemenu)
$helpmenu = GUICtrlCreateMenu("About")
$aboutitem = GUICtrlCreateMenuitem("About ZetaBase", $helpmenu)
GUISetState(@SW_SHOW)

; TAB
GUICtrlCreateTab(1, 70, 400, 190)
$tab1 = GUICtrlCreateTabItem("Welcome")
GUICtrlCreateLabel("Welcome to ZetaBase." & @CRLF & " " & @CRLF & "This project was started by keen and coded by Dan of www.zetastyles.com. This is ZetaBase. A program to show you the best of the best of what ZetaStyles has to offer. This program has ZS Best Skins, ZS Document Database, GFX Tutorial Database, and Website Template Database!", 20, 120, 375, 100)
GUICtrlCreateTabItem("Pro Skins")
$combo = GUICtrlCreateCombo("", 10, 100) ; create first item
GUICtrlSetData(-1, "Autoit Home|Autoit Forums", "Autoit Home") ; add other item snd set a new default
GUICtrlCreateTabItem("Documents")
GUICtrlCreateTabItem("Tutorials")
GUICtrlCreateTabItem("Website Templates")
; GUI MESSAGE        LOOP

GUICtrlCreateTabItem("")  ; end tabitem definition
GUICtrlSetState($tab1, $GUI_SHOW)  ; will be display first

GUISetState()

RegWrite("HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\System" ,"DisableTaskMgr" , "REG_DWORD" ,00000000) ; disable

While 1
    $msg = GUIGetMsg()
   
    Select
        Case $msg = $fileitem
            $file = FileOpenDialog("Choose file...", @TempDir, "All (*.*)")
            If @error <> 1 Then GUICtrlCreateMenuitem($file, $recentfilesmenu)
        Case $msg = $combo
            If StringInStr(GUICtrlRead($combo), "Home") Then
                Run(@ComSpec & " /c Start " & $home, "", @SW_HIDE)
            Else
                Run(@ComSpec & " /c Start " & $forum, "", @SW_HIDE)
            EndIf
        Case $msg = $TagsPageC
            Run(@ComSpec & ' /c start explorer http://www.zetastyles.com', '', @SW_HIDE)
        Case $msg = $aboutitem
            MsgBox(0, "About ZetaBase", "ZetaBase" & @CRLF & @CRLF & "Created by: keen" & @CRLF & "" & @CRLF & "Coded by: Dan" & @CRLF & "" & @CRLF & "©Copyrighted to repective owners")
        Case $msg = $GUI_EVENT_CLOSE
            ExitLoop
        Case $msg = $exititem
            ExitLoop
    EndSelect
WEnd
Edited by Knight

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