Import and export scripts

You can import a script into the Actions panel or Script window. You can also export your scripts from the Actions panel to external ActionScript files. (When you use the Script window, exporting is unnecessary because you can instead save the AS file.)

If text in your scripts doesn’t look as expected when you open or import a file, change the import encoding preference.

Import an external AS file

  1. In the Script pane, place the insertion point where you want to locate the first line of the external script.
  2. Do one of the following:
    • In the Actions panel, select Import Script from the panel menu, or press Control+Shift+I (Windows) or Command+Shift+I (Macintosh).

    • In the Script window, select File > Import Script or press Control+Shift+I (Windows) or Command+Shift+I (Macintosh).

Export a script from the Actions panel

  1. Select the script to export. Then select Export Script from the Actions Panel menu, or press Control+Shift+X (Windows) or Command+Shift+X (Macintosh).
  2. Save the ActionScript (AS) file.

Set text encoding options

  1. Select Edit > Preferences (Windows) or Flash > Preferences (Macintosh), and select ActionScript in the Category list.
  2. Set any of these options:
    Open/Import

    Select UTF-8 Encoding to open or import using Unicode encoding, or select Default Encoding to open or import using the encoding form of the language currently used by your system.

    Save/Export

    Select UTF-8 Encoding to save or export using Unicode encoding, or select Default Encoding to save or export using the encoding form of the language currently used by your system.

Turn the export encoding warning off or on

  1. Select Edit > Preferences (Windows) or Flash > Preferences (Macintosh), and select Warnings in the Category list.
  2. Select or deselect Warn On Encoding Conflicts When Exporting ActionScript Files.

  This page on the Web