create card

Typecommand
DictionaryLCS
LibraryLiveCode Script
Syntax
create card [<cardName>] [in stack <stack>]
Synonymsnew card
Summary

Makes a new card with the same background (s) as the current card.

Introduced1.0
OSmac, windows, linux, ios, android
Platformsdesktop, server, mobile
Parameters
NameTypeDescription
cardName

The name property of the new card. If you don't specify a cardName, the new card's name is empty.

stack

A reference or and expression that evaluates to a reference to a stack. If you specify a stack, the card will be a member of that stack, otherwise it will be a member of the defaultStack.

Example
create card
create card "Main"
create card (field "output")
create card "Main" in stack "Stack"
Values
NameTypeDescription
It

The create card command places the ID property of the newly created card in the it variable.

RelatedKeyword: card, templateCard, it
Property: ID, defaultStack
Message: newCard
Command: clone, create, place, create stack
Object: stack
Glossary: property, current card, background, current stack, variable, command
Description

Use the create card command to add a new card to the current stack.

The new card is placed after the current card. If stackName is specified, it will be placed in stackName, otherwise in the defaultStack. When the card is created, you go to the new card.

Any groups on the current card whose backgroundBehavior is set to true will be placed on the newly-created card automatically.

Tagsobjects