I am new to Xojo (did a little VB programming).
I want something like a sub routine to us in my app and I am not sure what to use in Xojo. I am not looking for the code but do I use a method, module or class or is there a sub routine function? What I have is 32 BevelButtons in a control group. When one is pressed I need it to stay lit, no problem, but when a new button is pushed that should stay lit (ok no problem) but the previous choice should no longer be lit, like radio buttons. All of the buttons are toggle type. The code is simple, I just don’t want to have to put it in 32 times, once for each button…
Hi James. In Xojo a method is either a sub or a function depending if you return a value or not. IE. If you return a value then that is a function.
Ok got it. I read through the method section in The XOJO User guide Book1 Fundamentals and it makes sense. I will give it a go.
O M G! Somebody actually read the fine manual?!?!
Sadly, I have been going through them back and forth many times. I gain a little each time.
I know this consumes some time, James, but did you look into some of the recorded Webinars? While the manual may handle some features separately sometimes without the focus on a real life project, many things may become clearer by the programming webinars examples. In Introduction to Programming 201 you will find the methods broadly explained:
I started watching some of them last night, more today. I will watch this one you linked in a little bit.
F=Fine? hmmmmm I always used another word there…
But then lack of reading the manual, or doing a modicum of research ahead of time belongs in the Pet Peeves topic
not to mention the only difference between VB and XOJO in this regard is minor nomenclature…
We have over 50 hours of Real Studio and Xojo training videos at http://xojo.bkeeney.com/XojoTraining/ available to subscribers. In total there are well over 110 project files with source code that you can use in your own projects. We cover a lot of different topics. Our tag list is at http://www.bkeeney.com/bkeeney-tag-and-video-list/.
I think I’ve mentioned that one at least twice on the Pet Peeves thread