Memblocks
unles i missed sommet again
a gadget that alowys you to have a 3d scene in an app so world editers can be made just a thought any ways my first program and im stuck LOL
have a look at this code and tell me wot i need to add.
wot i want it to do is when the password is entered and enter is clicked for it 2 check the password and either give the right MsgBox or the rong one if the pass dont match here is my code so far.
Code: Select all
;- Window Constants
;
#MyWindow = 0
;- Gadget Constants
;
#MyStringGadget = 0
#MyTextGadget = 1
#MyButton_Enter = 2
#MyButton_Quit = 3
pass$ = "abc"
;- gaget code settings
If OpenWindow(#MyWindow, 366, 297, 395, 173, #PB_Window_SystemMenu | #PB_Window_SizeGadget | #PB_Window_TitleBar , "Crack Me No 1")
If CreateGadgetList(WindowID())
StringGadget(#MyStringGadget, 60, 70, 280, 30, "", #PB_String_Password)
TextGadget(#MyTextGadget, 60, 20, 280, 50, " Please Enter Your Password")
ButtonGadget(#MyButton_Enter, 100, 100, 100, 30, "Enter")
ButtonGadget(#MyButton_Quit, 200, 100, 100, 30, "Quit")
EndIf
EndIf
;the test pass routeen
Repeat
If GetGadgetText(0)=pass$
MessageRequester("Well Done", "Correct" , 0)
Else
MessageRequester("Bad Luck", "Incorrect", 0)
EndIf
Until EventID = #PB_EventCloseWindow
; ExecutableFormat=Windows
; CursorPosition=38
; FirstLine=1
; EOF
dbellis