Note: You must edit the script to specify the full path to the legend file.
Click the Compile button.
Attach the script to a button on the View GUI.
A. Compile the script. B. Switch to the Project window. C. Select Customize from the Project menu. D. On the Customize dialog box, click the Type dropdown arrow and click View. E. Select Buttons under Category. F. Click the New button. G. Double-click the Click property in the Customize dialog box. H. Type the name of the script in the Script Manager and click Select. I. Close the Customize dialog box.
For more information, see "Customize dialog box" in ArcView Help.