I'm trying to create a script that will just create folders and subfolders. I can create folders but what is the syntax to create a subfolder?
$folder = New-RoyalObject -Type RoyalFolder -Folder $royalDocument -Name "TestFolder" -Description "Test"
This will create the folder, how do I create a subfolder below this?
Never mind, I found out how to do this. For those wondering here is how:
#create a RoyalStore in memory
$royalStore = New-RoyalStore -UserName <username>
#create a RoyalDocument in memory
$documentName = "testdocument"
$documentPath = "c:\users\<profile name>\documents\new.rtsz"
$royalDocument = Open-RoyalDocument -Store $royalStore -FileName $documentPath
#create folders
$folder1 = New-RoyalObject -Type RoyalFolder -Folder $royalDocument -Name "Test" -Description "Test"
$folder2 = New-RoyalObject -folder $folder1 -Type RoyalFolder -Name "Subfolder"
Out-RoyalDocument -Document $royalDocument
Mike Graham
I'm trying to create a script that will just create folders and subfolders. I can create folders but what is the syntax to create a subfolder?
$folder = New-RoyalObject -Type RoyalFolder -Folder $royalDocument -Name "TestFolder" -Description "Test"
This will create the folder, how do I create a subfolder below this?
Never mind, I found out how to do this. For those wondering here is how:
#create a RoyalStore in memory
$royalStore = New-RoyalStore -UserName <username>
#create a RoyalDocument in memory
$documentName = "testdocument"
$documentPath = "c:\users\<profile name>\documents\new.rtsz"
$royalDocument = Open-RoyalDocument -Store $royalStore -FileName $documentPath
#create folders
$folder1 = New-RoyalObject -Type RoyalFolder -Folder $royalDocument -Name "Test" -Description "Test"
$folder2 = New-RoyalObject -folder $folder1 -Type RoyalFolder -Name "Subfolder"
Out-RoyalDocument -Document $royalDocument
Mike Graham
Never mind, I found out how to do this. For those wondering here is how:
#create a RoyalStore in memory
$royalStore = New-RoyalStore -UserName <username>
#create a RoyalDocument in memory
$documentName = "testdocument"
$documentPath = "c:\users\<profile name>\documents\new.rtsz"
$royalDocument = Open-RoyalDocument -Store $royalStore -FileName $documentPath
#create folders
$folder1 = New-RoyalObject -Type RoyalFolder -Folder $royalDocument -Name "Test" -Description "Test"
$folder2 = New-RoyalObject -folder $folder1 -Type RoyalFolder -Name "Subfolder"
Out-RoyalDocument -Document $royalDocument
-
What happened to the forum?
-
About this Forum
-
Security Information
-
Supported Secure Gateway (SSH) ciphers
-
Why is no remote file browser in SCP available?
-
What encryption is used in the rtsz files when enabled?
-
Royal TS V4 License File
-
How to resolve RDP resolution issues in Windows 7 with high resolution screen
-
Auto Fill in web page connection
-
How to reference custom properties in tasks and templates?
See all 275 topics