Derma Problems : A Nil Value and it is client side!!!

hello, i am back with anougher problem with derma concerning DLable. for some reason it keeps saying its a nil value even though its client side and i have done everything right. i cannot post you the error because my gmod is stupid and it wont let me copy things. here is the code


 function adminbank()
	if LocalPlayer():IsAdmin() then
		local DermaPanel = vgui.Create( "DFrame" )
		DermaPanel:SetPos( 150,50 )
		DermaPanel:SetSize( 600, 500 )
		DermaPanel:SetTitle( "Admin Bank" )
		DermaPanel:SetVisible( true )
		DermaPanel:SetDraggable( true )
		DermaPanel:ShowCloseButton( true )
		DermaPanel:MakePopup( true )

		function DermaPanel:Paint()
			surface.SetDrawColor( 0, 0, 0, 225 )
			surface.DrawRect( 0, 0, DermaPanel:GetWide(), DermaPanel:GetTall() )
		end

		local myLabel= vgui.Create("DLabel", DermaPanel)
		myLabel:SetText("Password:")
		myLabel:SizeToContents()
		myLable:SetPos( 5, 25);
		
		local myText = vgui.Create("DTextEntry", myParent)
		myText:SetText("Password goes here")
		myText:SetPos( 5, 32)
		myText:SetSize( 50 , 5 )
		
		local myLabel2= vgui.Create("DLabel", DermaPanel)
		myLabel2:SetText("Ammount")
		myLabel2:SizeToContents()
		myLable2:SetPos( 5, 37)
		
		local myText2 = vgui.Create("DTextEntry", myParent)
		myText2:SetText("How Much Do You Want")
		myText2:SetPos( 5, 45)
		myText:SetSize( 50 , 5 )
		
		local button = vgui.Create( "DButton", window );
		button:SetSize( 100, 30 );
		button:SetPos( 5, 55 );
		button:SetText( "ENTER" );
		button.DoClick = function( button )
			RunConsoleCommand("lobby_secret_bank", tostring(myText:GetValue()), tonumber( myText2:GetValue()));
		end
	end
end

concommand.Add("lobby_adminbank", adminbank)


Because typing an error over is impossible.

Also lua tags.

Spelling mistake.


myLabel:SizeToContents()
		myLable:SetPos( 5, 25);

thx

[lua]function adminbank()
if LocalPlayer():IsAdmin() then
local DermaPanel = vgui.Create( “DFrame” )
DermaPanel:SetPos( 150,50 )
DermaPanel:SetSize( 600, 500 )
DermaPanel:SetTitle( “Admin Bank” )
DermaPanel:SetVisible( true )
DermaPanel:SetDraggable( true )
DermaPanel:ShowCloseButton( true )
DermaPanel:MakePopup( true )

	function DermaPanel:Paint()
		surface.SetDrawColor( 0, 0, 0, 225 )
		surface.DrawRect( 0, 0, DermaPanel:GetWide(), DermaPanel:GetTall() )
	end

	local myLabel= vgui.Create("DLabel", DermaPanel)
	myLabel:SetText("Password:")
	myLabel:SizeToContents()
	myLabel:SetPos( 5, 25);
	
	local myText = vgui.Create("DTextEntry", DermaPanel)
	myText:SetText("Password goes here")
	myText:SetPos( 5, 32)
	myText:SetSize( 50 , 5 )
	
	local myLabel2= vgui.Create("DLabel", DermaPanel)
	myLabel2:SetText("Ammount")
	myLabel2:SizeToContents()
	myLabel2:SetPos( 5, 37)
	
	local myText2 = vgui.Create("DTextEntry", DermaPanel)
	myText2:SetText("How Much Do You Want")
	myText2:SetPos( 5, 45)
	myText:SetSize( 50 , 5 )
	
	local button = vgui.Create( "DButton", DermaPanel );
	button:SetSize( 100, 30 );
	button:SetPos( 5, 55 );
	button:SetText( "ENTER" );
	button.DoClick = function( button )
		RunConsoleCommand("lobby_secret_bank", tostring(myText:GetValue()), tonumber( myText2:GetValue()));
	end
end

end

concommand.Add(“lobby_adminbank”, adminbank)[/lua]

Fixed you need to make sure there are spaces ops i mean height to allow other boxes.

[lua] local myLabel= vgui.Create(“DLabel”, DermaPanel)
myLabel:SetText(“Password:”)
myLabel:SizeToContents()
myLable Name misspelt :SetPos( 5, 25);

	local myText = vgui.Create("DTextEntry", myParent << Error makes it go outside the box)
	myText:SetText("Password goes here")
	myText:SetPos( 5, 32)
	myText:SetSize( 50 , 5 )
	
	local myLabel2= vgui.Create("DLabel", DermaPanel)
	myLabel2:SetText("Ammount")
	myLabel2:SizeToContents()
	myLable2 << Name misspelt :SetPos( 5, 37)
	
	local myText2 = vgui.Create("DTextEntry", myParent << Error makes it go outside the box )
	myText2:SetText("How Much Do You Want")
	myText2:SetPos( 5, 45)
	myText:SetSize( 50 , 5 )

	local button = vgui.Create( "DButton", window << Error makes it go outside the box );
	button:SetSize( 100, 30 );
	button:SetPos( 5, 55 );
	button:SetText( "ENTER" );
	button.DoClick = function( button )
		RunConsoleCommand("lobby_secret_bank", tostring(myText:GetValue()), tonumber( myText2:GetValue()));
	end

[/lua]