Tab/card help
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller
Tab/card help
It;s clear Revolution is a very powerful tool but I'm having trouble with some really basic concepts which I hope someone can help m,e with before I go down the wrong path.
First of all, should I think of a stack as an application and each card as a screen within the application? I think that's a correct analogy but not sure.
Next, I created a new stack and a card but I can't for the life of me figure out how to give a name to the card. I typed a name into the basic properties of the card but the menu bar for the card continues to display "Untitled" each time I open the stack.
Next, a tab panel onto my card and positioned several objects onto tab 1 but how do I add objects to tab 2 and tab 3?
Thanks in advance for any help.
Pete
First of all, should I think of a stack as an application and each card as a screen within the application? I think that's a correct analogy but not sure.
Next, I created a new stack and a card but I can't for the life of me figure out how to give a name to the card. I typed a name into the basic properties of the card but the menu bar for the card continues to display "Untitled" each time I open the stack.
Next, a tab panel onto my card and positioned several objects onto tab 1 but how do I add objects to tab 2 and tab 3?
Thanks in advance for any help.
Pete
Hi Pete,
please see this page and load and examine all the stacks there:
http://www.runrev.com/developers/tutori ... nferences/
Especially my stack about "Controls"!
ther you will find answers to this and a lot of other future questions
Best
Klaus
please see this page and load and examine all the stacks there:
http://www.runrev.com/developers/tutori ... nferences/
Especially my stack about "Controls"!
ther you will find answers to this and a lot of other future questions

Best
Klaus
Re: Tab/card help
Hi Pete,
here some quick answers to your other questions.
if you need to dispaly the name of the current card you could put this into the script of the stack (yes of the stack!)
This way the script will be called everytime you go to a card and you do not need to put this handler into the script of every card!
Et voila, the cards name in the titlebar 
Best
Klaus
here some quick answers to your other questions.
To be correct: A stack is ONE (of possibly more) window of an application.phaworth wrote:First of all, should I think of a stack as an application and each card as a screen within the application? I think that's a correct analogy but not sure.
The "title" of a stack will alway display the stacks name "automatically".phaworth wrote:Next, I created a new stack and a card but I can't for the life of me figure out how to give a name to the card. I typed a name into the basic properties of the card but the menu bar for the card continues to display "Untitled" each time I open the stack.
if you need to dispaly the name of the current card you could put this into the script of the stack (yes of the stack!)
This way the script will be called everytime you go to a card and you do not need to put this handler into the script of every card!
Code: Select all
on opencard
set the title of this stack to the short name of this card
end opencard

Best
Klaus
Klaus, I've been through the Controls demo stack you recommended and it was very useful, thank you. Navigation around my tab panel now works perfectly and I'm beginning to see how to use scripts at various levels.
Before I get too much further, I'd like to make sure I have the correct structure for my application. I understand the concept of stacks and cards but just came across the term substack so now I'm wondering the circumstances in which substacks should be used.
Am I right in thinking that cards in a main stack always open in the same window whereas opening a substack from the main stack results in a new window being displayed?
This seems like a key concept for my application. It has a main menu and 3 or 4 separate functional areas, each of which should be capable of having it's own window open, so there could be 3 or 4 windows open at any one time.
Thanks,
Before I get too much further, I'd like to make sure I have the correct structure for my application. I understand the concept of stacks and cards but just came across the term substack so now I'm wondering the circumstances in which substacks should be used.
Am I right in thinking that cards in a main stack always open in the same window whereas opening a substack from the main stack results in a new window being displayed?
This seems like a key concept for my application. It has a main menu and 3 or 4 separate functional areas, each of which should be capable of having it's own window open, so there could be 3 or 4 windows open at any one time.
Thanks,
Pete, your understanding about the windowing relationship between stacks and substacks is basically correct.
Although it's also true to say that an application can consist of many stacks which do not necessarily have to be sub-stacks of one main stack.
For example, if in the IDE you enable the following menu:
View/Revolution UI Elements In Lists
then open the Application Browser (at the following menu: Tools/Application Browswer), you will be able to see all the stacks (including some with sub-stacks) that make up the Rev IDE. (To hide these again, just toggle the View/Revolution UI Elements... menu).
There is even more one can learn on the relationship between windows/stacks, and I hope that my additional information hasn't confused you.
Please ask if you'd like more information.
Although it's also true to say that an application can consist of many stacks which do not necessarily have to be sub-stacks of one main stack.
For example, if in the IDE you enable the following menu:
View/Revolution UI Elements In Lists
then open the Application Browser (at the following menu: Tools/Application Browswer), you will be able to see all the stacks (including some with sub-stacks) that make up the Rev IDE. (To hide these again, just toggle the View/Revolution UI Elements... menu).
There is even more one can learn on the relationship between windows/stacks, and I hope that my additional information hasn't confused you.
Please ask if you'd like more information.