Kemerd Posted March 2, 2013 Author Share Posted March 2, 2013 Well I was programming a comand in Eclispe, trying to use a command to open a panel.``` Case "/redeemcode" If redeemcodepanel = Visible Then redeemcodepanel.Visible = False Else redeemcodepanel = Visible```That's in modInput, and I'm trying to control something on frmMain. Any help?```Compile error:Variable not defined[OK] [HELP]```Giving me that error. Link to comment Share on other sites More sharing options...
Kemerd Posted March 2, 2013 Author Share Posted March 2, 2013 Gonna try to make a global variable with```Public codevisible As BooleanIf redeemcodepanel.Visible = True Thencodevisible = 0Elsecodevisible = 1End Sub```Posted in frmMainThen modify the command to…. ya know. Link to comment Share on other sites More sharing options...
hisherwin Posted March 2, 2013 Share Posted March 2, 2013 case "/redeemcode"If frmMain.redeemcodepanel.visible = true thenfrmmain.redeemcodepanel.visible = falseelsefrmmain.redeemcodepanel.visible = trueEnd iffix the code Link to comment Share on other sites More sharing options...
Kemerd Posted March 2, 2013 Author Share Posted March 2, 2013 Grrr. Not working… does anyone have any ideas on how I could do that? Declare the visibility of the panel global? Link to comment Share on other sites More sharing options...
jcsnider Posted March 2, 2013 Share Posted March 2, 2013 ```frmMain.redeemcodepanel.visible = not frmMain.redeemcodepanel.visible```?? Link to comment Share on other sites More sharing options...
Kemerd Posted March 2, 2013 Author Share Posted March 2, 2013 Sorry I didn't see your first post sherwin, eclispe was glitching. I forgot about stating frmMain. Link to comment Share on other sites More sharing options...
hisherwin Posted March 2, 2013 Share Posted March 2, 2013 just refresh the page Link to comment Share on other sites More sharing options...
Kemerd Posted March 2, 2013 Author Share Posted March 2, 2013 It works, so thanks! I haven't programmed in a while, so I'm a bit rusty. Link to comment Share on other sites More sharing options...
cheatking Posted March 4, 2013 Share Posted March 4, 2013 Dear god man, learn to camelCase. Make it that little bit easier to read. [background=rgb(248, 248, 248)]redeemCodePanel [/background] Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now