Analyze VBA source
xlide_analyze_sourceRuns static analysis over VBA source you are holding, before it is written to a file. Use it to check code you have just generated: it costs nothing, needs no file, and catches the compile errors that would otherwise surface in front of…
Instructions
Runs static analysis over VBA source you are holding, before it is written to a file. Use it to check code you have just generated: it costs nothing, needs no file, and catches the compile errors that would otherwise surface in front of the user. Pass host so the code is measured against the right object model, and file_path instead if the code is destined for a file that already exists, which resolves calls into the rest of that project. Use offset and next_offset to read later findings from a long result.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| host | No | 'excel', 'word', 'powerpoint' or 'access'. Empty checks the language alone, with no host object model. | |
| kind | No | 'standard', 'class', 'document' or 'userform'. | standard |
| offset | No | Skip this many findings. | |
| source | Yes | The VBA source to check. | |
| file_path | No | An existing Office file this module belongs to. Its other modules are read as context, so calls into them resolve; only this source is analyzed. Overrides host. | |
| max_results | No | Return at most this many findings. | |
| module_name | No | Name to report problems against. | Module1 |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||