Change editor types after creating a BookVars file

If you need to change editor types after creating a BookVars file, you'll probably need to re-create the BookVars file from scratch. If you're sure there are no high-ASCII characters, you can just change the EditorType parameter (in the General section) accordingly (1=external editor; 0=internal editor). Before making this change, you may want to make a backup copy of the file.

If you have only one variable group, the easiest way to switch editors is to first verify that you have imported the latest variables into your Frame documents, then generate a new BookVars file (selecting the correct editor type).

If you have multiple variable groups, you will need to perform a series of import and generate operations, while copying and pasting the resulting groups into a new hand-build BookVars file. The following procedure described one possible method:

  1. In a temporary folder, create a new book file that includes a single temporary document. Give the book the same name as your real book file.
  2. Copy the BookVars file into the temporary folder and make a copy of the BookVars file. You should have two BookVars files, <bookname>-BookVars.INI and ORIGINAL_<bookname>-BookVars.INI.
  3. Use the Import Variables command and import the first variable group into the book.
  4. Use the Generate BookVars File command and overwrite the BookVars file specifying the new text editor type. Be sure to select the variable types that are included in this variable group (you may need to look in the "original" copy of the BookVars file to get this right).
  5. Rename the newly generated BookVars file to <groupname>_<bookname>-BookVars.INI.
  6. Copy the original BookVars file to <bookname>-BookVars.INI and repeat steps 3 through 6 on each variable group.
  7. Now you should have a separate groupname BookVars file for each variable group. Open the first file in a text editor, then copy and paste the variable group section from each groupname BookVars file into the first one. Edit the Groups section so the Count parameter matches the number of groups defined, and there is a numbered entry for each group.

    For example, if you have 4 groups, the Groups section could look like the following:

    [Groups] 
    Count=4 
    1=GroupOne 
    2=GroupTwo 
    3=GroupThree 
    4=GroupFour
  8. Now rename the merged BookVars file to <bookname>-BookVars.INI, and it should work properly using the new editor.
Note: We realize that this is a very convoluted procedure. Please let us know if this is actually something that you do frequently, and we'll make it into a new command for an update to this plugin.