im making a login gui and im a bit stuck.... look
addEventHandler("onClientGUIClick",Cancel,CreateLoginWindow,false)
function CreateLoginWindow()
wdwLogin = guiCreateWindow(226,146,372,233,"[Admin Login System]",false)
guiWindowSetMovable(wdwLogin,false)
guiWindowSetSizable(wdwLogin,false)
tabpanel = guiCreateTabPanel(0.0242,0.0858,0.9489,0.8755,true,wdwLogin)
tab1 = guiCreateTab("Login",tabpanel)
login = guiCreateButton(0.1000,0.8611,0.2436,0.1167,"Login",true,tab1)
username = guiCreateLabel(0.0113,0.1167,0.3768,0.15,"UserName:",true,tab1)
guiLabelSetColor(username,255,255,255)
guiLabelSetVerticalAlign(username,"top")
guiLabelSetHorizontalAlign(username,"left",false)
guiSetFont(username,"default-bold-small")
password = guiCreateLabel(0.0113,0.2889,0.3768,0.15,"Password:",true,tab1)
guiLabelSetColor(password,255,255,255)
guiLabelSetVerticalAlign(password,"top")
guiLabelSetHorizontalAlign(password,"left",false)
guiSetFont(password,"default-bold-small")
username = guiCreateEdit(0.2266,0.1,0.3598,0.1389,localPlayerName,true,tab1)
password = guiCreateEdit(0.2266,0.2611,0.3598,0.1389,"",true,tab1)
Canel = guiCreateButton( 0.4, 0.85, 0.20, 0.15, "Cancel", true,tab1 )
guiEditSetMasked(password,true)
tab2 = guiCreateTab("Info",tabpanel)
guiSetVisible(wdwLogin,false)
end
Im trying to make the cancel button work so it cancels the window