• dbutton problem
    5 replies, posted
so I',m wanting to close the menu this button is on but then I want to open the 2nd dframe ? is this possible sorry not a pro a lua local dbutton = vgui.Create( "DButton", frame ) dbutton:SetSize(50,20) dbutton:SetPos(200,200) dbutton.DoClick = function() frame:Close() frame2:Open() end
Use Panel/MakePopup instead of Open() (that doesnt exist)
You can show the second frame by using http://wiki.garrysmod.com/page/Panel/Show and hide the previous frame with Panel/Hide or just DFrame/Close when you are using a DFrame, however you will have to create or target a different DFrame instead of using Panel/Show unless you create 2 DFrames from the beginning and hide one by default
@Trackster whats worse being corrected by citizen hack member or knowing lua for almost 10 years and forgetting stupid shit, haha just kidding tho completely forgot about that wasn't even thinking but ty bro
did you create frame2?
yes I did
Sorry, you need to Log In to post a reply to this thread.