Last fall when the Flash Builder “Burrito” beta was released at MAX, I shared several templates that I created.
It’s easy to share templates with others, which is great for teams or just for helping others so they don’t have to re-invent the wheel. Templates (like other settings) are not persisted between workspaces by default, so if you use multiple workspaces in Flash Builder, this is a way you can get your templates in your workspaces too.
Importing templates
To add a template to Flash Builder 4.5 (such as one of the ones I’ve shared):
- open Flash Builder preferences
- expand the Flash Builder > Editors > Code Templates section
choose the category for the templates you’re importing (ActionScript, CSS, Flash Builder, or MXML)
- Click the “Import” button and browse to the file containing the templates you want to import (an XML file).
- Choose “Open” and the templates are imported into Flash Builder.
Exporting templates
To share your own templates with others:
- open Flash Builder preferences
- expand the Flash Builder > Editors > Code Templates section
- choose the category for the templates you’re importing (ActionScript, CSS, Flash Builder, or MXML)
- select the template(s) you want to export. (If you select more than one, they are exported into a single XML file.)
- Click the “Export” button and browse to the location where you want to save the template XML file.
- Choose “Save” and the template XML file is saved.