PureBytes Links
Trading Reference Links
|
No, I haven't, but I will.
Another response suggested using #Include and passing the variable to
a procedure as a parameter and that is working fine.
Now tomorrows task is to try static vars.
Thanks
Graham
--- In amibroker@xxxxxxxxxxxxxxx, "bingk66" <bing.kwok@xxx> wrote:
>
> Have you tried static variables staticvarget and staticvarset ??
>
>
>
> --- In amibroker@xxxxxxxxxxxxxxx, "Graham Johnson" <grahamj@>
> wrote:
> >
> > For the sake of code re-use, I wish to have CBT code in its own
AFL
> and
> > access it using SetCustomBacktestProc("<filename>");
> >
> > That works fine except that in the Main.afl there is a variable
set
> for
> > Max Open Positions and I want to pass that value to CBT.afl for
> > inclusion in the backtest report using AddCustomMetric.
> >
> > Tried using Global but that didn't get a result - CBT.afl didn't
> > recognise the variable name.
> >
> > I presume that from Main.afl I could write the value to a file
and
> then
> > retrieve the file in CBT.afl. Gets a bit messy when wanting to
> pass
> > the values of several variables.
> >
> > Is there a better way, please?
> >
> > Graham
> >
>
------------------------------------
Please note that this group is for discussion between users only.
To get support from AmiBroker please send an e-mail directly to
SUPPORT {at} amibroker.com
For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/
For other support material please check also:
http://www.amibroker.com/support.html
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/amibroker/
<*> Your email settings:
Individual Email | Traditional
<*> To change settings online go to:
http://groups.yahoo.com/group/amibroker/join
(Yahoo! ID required)
<*> To change settings via email:
mailto:amibroker-digest@xxxxxxxxxxxxxxx
mailto:amibroker-fullfeatured@xxxxxxxxxxxxxxx
<*> To unsubscribe from this group, send an email to:
amibroker-unsubscribe@xxxxxxxxxxxxxxx
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
|