top of page

How to Read Final Draft's .fdx Code

  • Writer: Staff
    Staff
  • Oct 14, 2022
  • 3 min read

Updated: Oct 27, 2022

Sometimes you have to go straight to the source


ree

Final Draft files are notoriously fragile. Open an .fdx in a different version of Final Draft, email an .fdx to a friend, talk about an .fdx in the next room: all of these behaviors can corrupt your script. And that's not even mentioning the persistent issues that Final Draft refuses to address with its Navigator Pane. Sometimes to get a file up and working again, you have to go into the code itself to sort things out.


Disclaimer

Final Draft does not want you to do this. One wrong keystroke here can have massive consequences for your file, so it should only be done by expert-level users or panicked script coordinators on a Sunday morning.


Always Back Up Your Files

Before you do anything, make a copy of your file. Email it to yourself, put it in your DropBox, do something so that you always have a clean original copy available. Even if it's not working. Keeping backups of all your files should be at the top of your best practices as a script coordinator. A professional DropBox account isn't a bad idea since provides you tools to revert a file back to a previous version. It's not a bad idea to keep all of your scripts, including your autosaves, in your DropBox.


Cracking Open a .fdx


Getting to the code is remarkably easy. Right-click or control+click on your copied .fdx. Select Open With, then TextEdit. Boom. You're in. It'll look something like this.

ree

As far as code goes, it's relatively easy to parse. Paragraphs of text are contained between <Paragraph> and </Paragraph>, text and dialogue are indicated by <text> and <dialogue>, and revision sets are identifiable as <RevisionID="1"> (where 1 is the first round of revisions , 2 is the second, etc).

Fixing What Final Draft Won't


Since Final Draft version 9, FD has a persistent inconsistency that, over a decade later, they still refuse to address when it comes to Characters and Reports.


Reports are generally built based on the SmartType database. If you rebuild Locations, then a Locations report will only show the locations currently in the script. The same goes for Extensions, Transitions, etc.


Characters, however, is a different story. Even if you rebuild your character list in SmartType, reports will still pull up names of characters no longer in your script. Characters need to be manually deleted from each scene they previously appears in using the Scene option in the Navigator Pane. This is cumbersome and an outright waste of time. Adjusting it in the code, however, is a breeze. Simply use ⌘+F to search for <SmartType>. <Characters> will be the first section immediately after.

ree

This is where Reports will pull its character list from, and deleting a name here will completely eliminate them once and for all.


Secret Solutions


Now that you're deep in the mainframe, you can pull off some fancy tricks here that don't natively exist in Final Draft.


For example, let's say that a number of writers worked on a set of rewrites. Each writer used their own revision set so that the showrunner could keep track of changes. This creates an issue when it's time to publish, however, because you can't "collapse" all of these revisions into one all-inclusive set of blue pages. At least, not without going back and highlighting every writers' work and setting it to one unified revision.


In the code, you can do a Find and Replace for each user's revision set <RevisionID="2">, <RevisionID="3">, etc, and replace them with <RevisionID="1">. Now, all those changes will be assigned to the same Revision ID. Additionally, Final Draft draft's innate Find function does not register Dual Dialogue. A search through the code, however, makes it easy to see what the Find function may have missed, a crucial step if a name or location is replaced.


But Be Careful

Slippery fingers and overlooked typos can make it impossible for Final Draft to open the file after you've been tooling around in it. And Final Draft may not be too thrilled to dig through your handy work to repair it. Always, always, always backup your work.

 
 
 

Comments


Hey there, script coordinators. Get updates distro'd straight to your inbox. 

Thanks for subscribing!

© 2022 by Villains and Thieves.

bottom of page