$ps.file.removeSection
Overview¶
Deletes a specified section using "$ps.file" in "Server Script". All subdirectories and files in the section will be deleted.
Prerequisites¶
DisableServerScriptFile in "Script.json" must be set to false.
Syntax¶
Parameters¶
| Parameter | Type | Required | Description |
|---|---|---|---|
| section | string | Yes | Section name. For details on sections, see "About Sections" in "$ps.file". |
Return Value¶
Returns true if the section can be deleted, false if it cannot be deleted.
Exceptions¶
If an exception occurs in C#, the server script will throw an exception by putting the exception class name and error message into the Error object.
Usage Examples¶
The following example deletes a specified section in the web server.
JavaScript¶
Supported Versions¶
| Supported versions | Body |
|---|---|
| 1.4.12.0 and later | Added function |