Article Preview
Buy Now
COLUMN
Windows Basics
Working with windows (not the OS)
Issue: 7.3 (March/April 2009)
Author: Marc Zeedar
Author Bio: Marc taught himself programming in high school when he bought his first computer but had no money for software. He's had fun learning ever since.
Article Description: No description available.
Article Length (in bytes): 21,708
Starting Page Number: 42
Article Number: 7312
Resource File(s):
7312.zip Updated: 2009-03-02 13:37:17
Related Link(s): None
Excerpt of article text...
Windows are one of the most basic visual structures of a Graphical User Interface, yet working with them within REALbasic can be confusing for the beginner. Today we're going to explore how to show, hide, and close windows, work with different types of windows, create an app that lets us open multiple windows, and we'll even make a dynamic menu of all our app's open documents. I'll also show how to make a simple Splash screen for your applications.
Basic Window Handling
On the surface, adding a window to a REALbasic project is easy: just click the "New Window" button in the IDE and RB adds a number window to the project. Working with the window is also easy: double-click on it to open it in the Editor and drag controls onto the window. You can also refer to the window by name within code, so working with the window should be easy, right?
Well, things start to get complicated at this point. For instance, how do you display this second window? With a single-window app, REALbasic automatically displays the first window by default. But additional windows will not automatically display. You must manually tell them to display. For instance, to get the second window to display at launch you could add this code to
App.Open
:
...End of Excerpt. Please purchase the magazine to read the full article.