244
Third-Party Add-Ins
At start-up, the program executes any scripts it finds listed in these Windows Registry
keys:
HKEY_CURRENT_USER\Software\Allaire\HomeSite45\RunOnce
HKEY_CURRENT_USER\Software\Allaire\Studio45\RunOnce
HKEY_CURRENT_USER\Software\Allaire\JRStudio3\RunOnce
If you want to distribute an add-in for one or more of these programs, you can use the
appropriate key to run a script that, for example, creates a toolbar for your application
the next time the program starts. For HomeSite, you would add a string entry whose
value contains the full path to the script you want executed, like this:
"MyAppScript"="c:\\MyApp\\MyAppScript.bas"
Sub Main
const
TB_NAME = "MyApp"
Dim
app
set
app = Application
’ delete toolbar if it already exists
if
app.ToolbarExists(TB_NAME)
then
app.DeleteToolbar(TB_NAME)
end if
’ recreate toolbar
app.CreateToolbar TB_NAME
’ dock it to the bottom
app.SetToolbarDockPos TB_NAME, 2
’ add app toolbutton
app.AddAppToolbutton TB_NAME, "c:\MyApp\MyApp.exe", "", "Click to run
MyApp"
’ add tag toolbutton
app.AddTagToolbutton TB_NAME, "<div>", "</div>", "DIV Toolbutton",
"DV", ""
’ add script toolbutton
app.AddScriptToolbutton TB_NAME, app.A "test.bas" , "Script
Toolbutton", "SC", ""
’ add VTM toolbutton
app.AddVTMToolbutton TB_NAME, app.A
"Extensions\TagDefs\HTML\div.vtm" , "VTM Toolbutton", "VT", ""
End Sub
After these keys are read, the program deletes the entries so that they won’t be
executed again.
Scripting support opens up numerous possibilities for third-party developers. For the
latest news on third-party add-ins, check the Allaire Developer site.
Summary of Contents for COLDFUSION STUDIO 4.5-USING COLDFUSION...
Page 1: ...Allaire Corporation Using ColdFusion Studio ColdFusion Studio 4 5 for Windows 95 98 NT4 2000...
Page 16: ...xvi Contacting Allaire...
Page 90: ...82...
Page 130: ...122...
Page 133: ...141 Two VTML tags CAT and E let you customize the content of these dialog boxes...
Page 182: ...190...