New topic: Global vars
<http://forums.realsoftware.com/viewtopic.php?t=41964> Page 1 of 1 [ 6 posts ] Previous topic | Next topic Author Message gunthard Post subject: Global varsPosted: Mon Dec 26, 2011 5:48 pm Joined: Mon Dec 26, 2011 5:38 pm Posts: 5 I am new to RealBasic and cannot dim vars globally. I read that I have to put thhem into modules. But I did not get it. Can someone send a complete projekt file with some global vars? to: [email protected] Thank you Gunthard Top Jym Post subject: Re: Global varsPosted: Mon Dec 26, 2011 10:09 pm Joined: Sat Oct 01, 2005 5:19 pm Posts: 2804 I'm not sure what you don't get. Go to the Program tab in the IDE. Click on Add Module. Double click the module that was just added in the list. Click Add Property, now you have a global Variable of whatever type you want. Top swort Post subject: Re: Global varsPosted: Mon Dec 26, 2011 10:26 pm Joined: Mon May 31, 2010 5:35 am Posts: 1841 Location: Netherlands Jym wrote:I'm not sure what you don't get. Go to the Program tab in the IDE. Click on Add Module. Double click the module that was just added in the list. Click Add Property, now you have a global Variable of whatever type you want. don't forget the icon on the right when you add property "global" is the "world" icon _________________ SWORT⢠- Windows Vista, Windows XP, Windows 7, Linux Mint 11 and Mac OSX Lion - REAL Studio Enterprise(latest) and WEB Edition(latest) - Plugins (MBS Complete, ToringoLib, Einhugur, VanHoek + Some open source plugins) For Dutch User Groups ask me to enter! Top kermit Post subject: Re: Global varsPosted: Tue Dec 27, 2011 3:11 am Joined: Mon May 30, 2011 12:56 am Posts: 300 And another approach is to put the variables as properties of the application, again with the world icon selected. Then, you refer to them as app.myVariable1 , or app.szThing = "hello" Top Eclipse Post subject: Re: Global varsPosted: Tue Dec 27, 2011 8:22 am Joined: Sat May 19, 2007 6:01 am Posts: 125 http://www.syscare.se/files/addProperty.jpg I'm not sure this is what you're looking for, but at least part of the answer is in this image. I hope it helps!! Top gunthard Post subject: Re: Global varsPosted: Tue Dec 27, 2011 3:42 pm Joined: Mon Dec 26, 2011 5:38 pm Posts: 5 Thank you all for your hints. I did not click the global icon. These 3 icons are so small in my ide, it is almost impossible to click them. Gunthard Top Display posts from previous: All posts1 day7 days2 weeks1 month3 months6 months1 year Sort by AuthorPost timeSubject AscendingDescending Page 1 of 1 [ 6 posts ]
-- Over 1500 classes with 29000 functions in one REALbasic plug-in collection. The Monkeybread Software Realbasic Plugin v9.3. http://www.monkeybreadsoftware.de/realbasic/plugins.shtml [email protected]
