|
這得先去鑽一下User's Guide中Plug-in in AFL提到的部份
Plug-in in AFL
This section describes regular plug-in DLLs. If you are interested in ActiveX plugins check "COM support in AFL" section.
Plugin interface
AmiBroker Plugin interface allows to call an external module (DLL library) directly from AFL. Such a library can expose multiple functions that can be used in your trading systems, indicators, commentaries, scans and explorations. The plugin DLL can be created using any C/C++ compiler, Delphi and other languages supporting creation of regular DLLs. As the code of a plug in is compiled to a native processor machine code it runs several times faster than AFL. Also since you can use full power of C/C++ (or other) language to build the most complex functions with ease.
In addition to exposing functions to AFL, plugin DLLs have ability to call back AFL built-in functions, directly retreive and set AFL variables and support automatic syntax colouring of functions exposed by the plugin.
A detailed description of plugin interface and the sample code of plug in DLL are included in the AmiBroker Development Kit (ADK). The ADK is available for registered users only (downloadable from members area).
Getting 3rd party plugins
Freeware 3rd party plugins are available for download from http://www.amibroker.net/3rdparty.php
Using third-party plugins:
To use third-party plugin DLL just copy the DLL file to the Plugins folder in the AmiBroker directory. Then run AmiBroker. Then choose Tools->Plugins menu. In the Plugins window you should see the list of all loaded plugin DLLs. If AmiBroker was running when you copied the DLL you should click on "Unload" and then on "Load" button. This will force rescanning the Plugins folder and loading the DLLs.
When the plugin DLL is loaded the new functions exposed by this DLL become available to all your AFL formulas. For the list of functions exposed by plugin you should consult the documentation of the plugin itself.
IMPORTANT NOTE: AmiBroker makes no representations on features and performance of non-certified third-party plug-ins. Specifically certain plug-ins can cause instabilities or even crashes. Entire use of non-certified third-party plugins is at your own risk.
這玩意→AmiBroker Development Kit (ADK) |
|