Create, rename or delete a form
xlide_manage_formCreate, rename, or delete UserForms and Access forms/reports in Office files, preserving the paired designer and code module. Use to manage designs before adding controls and writing event procedures.
Instructions
Creates a UserForm, or an Access form or report, and saves the file. A form is a designer storage and a code module of the same name, and this writes both, which is why it exists rather than xlide_write_module. Renaming and deleting work on Access designs, where both halves move together; for a UserForm they are refused, because nothing here can move the designer storage and doing half of it loses the form. Add controls afterwards with xlide_edit_form, and write its event procedures with xlide_write_module.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| width | No | For create. Points for a UserForm, twips for Access. | |
| action | Yes | 'create', 'rename' or 'delete'. | |
| design | No | For create in Access: 'form' or 'report'. Elsewhere, a form. | form |
| height | No | For create. | |
| caption | No | For create: the caption it opens with. | |
| new_name | No | For rename: the new name. | |
| file_path | Yes | Absolute path to the Office file. | |
| form_name | Yes | The form or report to act on. | |
| allow_protected | No | Ask the user first. | |
| allow_invalidate_signature | No | Ask the user first. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||