Advertising banner:

History
 
 LFS13
Home • Help • Administration • FirstClass Scripting • LFS13
 
COPY



Function
The COPY command is the scripting equivalent to the COPY action available in the Application Developer rule. The COPY command works with variables to enable the administrator to create objects with different names while maintaining the structure, leaf items, aliases, permissions, rules and group membership. The COPY command will copy leaf items, containers, and aliased containers. Permissions, rules, and group membership are also duplicated.
All membership lists will be empty.
Separate the components of the path with colons. The PATHCHAR command can be used to change the default path character.
572004_44255_0.pngImportant
If the COPY command is used against conferences or calendars without variables, the resulting containers must be renamed before they will function normally.
06092010_122716_1.jpg        Note
If you want to create an alias of an existing object rather than a duplicate copy, use the LINK SPECIAL, LINK PATH, or LINK USER commands.



Syntax
COPY targetpath newpath +nr -c
Parameters


targetpath
The location of the existing object, relative to the administrator's Desktop.
newpath
The path of the new location, relative to the administrator's Desktop.
+r
Recursive. Copies subcontainers.
+n
Includes the target path container.
-c
Excludes content.
{}
Lets you immediately follow the field ID with a digit.




Examples
To copy the leaf items of a folder to another folder, enter:
COPY "General Conferences:HR Staff:Current Policies" "General Conferences:HR Staff:Policy Revisions for 2009"
The target folder, Policy Revisions for 2009, must exist before the command is sent.
To copy a folder with all its contents including leaf and subcontainers, enter
COPY "General Conferences:HR Staff:Current Policies" "General Conferences:Management" +rn



Related commands
EXPORT, ENABLEFIELDSUBSTITUTION, IF, MOVE, PGADD, RENAME commands can be used to combined with COPY to create custom workflow scripts.