Error getting tags :
error 404Error getting tags :
error 404 go | revDocs | RunRev
Welcome Guest (Log in)
Product Edition
Expander triangle
go [invisible] [to] card [of stack] [as mode|in [a] new window|in window] go [invisible] [to] {first | prev[ious]| next | last | any} [marked] [card] go [invisible] [to] {recent | start | finish | home} card go [invisible] [to] {forward | forth | back[ward]} [number]} [card[s]]
Platform Support
MacOS,Mac OS X,Windows,Linux
None required
Navigates to another card or stack.

go to card "Hemingway" -- in the defaultStack
go to stack "Controls" as palette
go to next marked card
go back 7 cards
go invisible stack "Preferences"
go stack URL "" in a new window

Additional Comments
Expander triangle

Use the go command to move to another card in the current stack, to open a stack and go to a card within it, or to move backward and forward among recently visited cards.


The card is any card reference. Cards can be described by their name, number, or ID properties.

The stack is any stack reference, or any file path or http URL reference that resolves to a stack file. If you specify a file path or http URL, the command opens the main stack of the specified stack file.

The mode is one of the following:

topLevel: editable window

palette: palette

modal: modal dialog box

modeless: modeless dialog box

sheet: sheet dialog box (appears in defaultStack)

drawer: drawer (appears in defaultStack, centered at left side if there's room)

The window is the name or windowID property of any open stack. If a window is specified, the stack opens in that window, replacing the stack that was previously displayed in that window.

The number is the number of Cards to move within the recent cards list.


If the stack is open, is closed but loaded into memory, or is listed in the current stack's stackFiles property, you can specify it simply by name:

go stack "My Stack"

Otherwise, you must include the stack's file path.

When going to a previously-unopened stack, if you don't specify a card, the go command displays the first card of the stack. If the stack is already open, the current card of the stack appears and the stack window is brought to the front.

If the lockScreen property is set to true, the go command does not bring an already-open stack to the front until the lockScreen is set to false. (Remember that the lockScreen is automatically set to false when all pending handlers finish executing.)

If you specify a mode, the stack opens in the specified mode. If you don't specify a mode, the stack opens in whatever mode is specified by the stack's style property.

When going to a stack, you can specify a mode or a window for the stack to appear in, but not both.

Important! The style of the stack, if it is anything other than "topLevel", overrides any mode you specify in a gocommand. For example, if you open a stack using the statement go stack "Some Stack" as modeless, and the style of "Some Stack" is set to "palette", it opens as a palette rather than a modeless dialog box, ignoring the mode you specified.

The sheet form can be used only on OS X systems. If you use this form on Mac OS, Unix, or Windows, the stack is displayed as a modal dialog box instead. If you don't specify a mode, the stack is opened with the mode specified by its style property.

If you specify a URL, the stack is downloaded from that URL and displayed. The stack must be in stack file format (that is, not compressed or archived). Stacks opened in this way are treated as unsaved stacks; the long name of such a stack is the same as its abbreviated name, until the stack is saved on a local disk. The downloaded stack is a copy: changes you make to the stack are not automatically made on the server the stack came from. To change the stack on the server, you must save the stack file locally and re-upload it.

You can go to the first, previous, next, or last card of the current stack. The form go any card goes to a random card in the current stack. If you include the marked parameter, the go command is restricted to Cards whose mark property is set to true.

Each card the user visits while the lockRecent property is false is placed in the recent cards list. You can use the go command to move among the previously-visited Cards:

* The go recent card form goes to the most recently visited card.

* The go start and go finish forms go to the first or last card in the recent cards list.

* The go home form goes to the first card in the application's main stack. (This form is included mainly for HyperCard compatibility; the statement go home does not do anything useful in the development environment.)

* The go back number form backs up number cards. The go forward number form moves forward in the recent cards list. "forward" and "forth" are synonyms.

If you use the go invisible form, the window or card change does not show on the screen. (When going to a stack, this form sets the stack's visible property to false.) Use this form of the go command to open a stack without displaying it on screen. To display the stack later, use the show command or set its visible property to true.

Any visual effects that have been queued with the visual effect command are displayed when the go command is executed (unless the screen is locked).

If the stack or card you specify doesn't exist, an error message is returned by the result function.

Tip: To test whether a stack or card exists before trying to go to it, use the there is aoperator:

if there is a card "Index" then go card "Index"

if there is a stack myPath then go card 2 of stack myPath

Changes to Revolution:

The sheet form was introduced in version 2.0. Previous versions did not support sheet dialogs.

User Comments
Expander triangle
User thumbnail
Phil Davis
Feb 17, 2009
CGI Environment Notes: Using the "go" command will generate a server error, even when used with the "invisible" modifier. To go to an unopened stack, set the defaultStack to the stack's filename. This will bring the stackfile into memory. Afterward you can reference the stack by its stack name instead of its filename.
User thumbnail
Craig Newman (dunbarx)
Jun 17, 2010
The "go to stack" form cannot use merely the name of a stack as a reference unless that stack has already been loaded into memory. The result will be set to "no such card" otherwise.
There are several ways around this for a stack that has never been opened:
1- Specify a full pathname as a stack reference. 2- Use the "answer file" command to navigate to the desired stack. 3- Set the "stackNames" property of the calling handler's stack to the target stack. See the dictionary for the correct form.