This function is called when a file with one of the registered file name extensions is selected and edited from the library window. For example, this function could check a template out of a document management system before it is edited.
Edit ( string fileName , ref string alternateFilename , ref bool hotdocsProcess )
Parameter | Description |
fileName | Complete path and file name for the selected library item. |
alternateFilename | Alternate file name for the selected library item. If the fileName is a document identifier, for example, this parameter could return the actual file name of the template file. |
hotdocsProcess | If this parameter is TRUE, HotDocs will open the template for editing. If it is FALSE, HotDocs will do nothing. |
The following Visual C# example prevents the normal HotDocs editing process for registered file types and informs the user with a message:
public void Edit(string FileName, ref string alternateFilename, ref bool hotdocsProcess) { MessageBox.Show(FileName + " is prevented from editing.") hotdocsProcess = false; }