[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [amibroker] Re: Problem with using "function" in AFL



PureBytes Links

Trading Reference Links

are you looking at the bottom of the edit window for error messages?
 
When you get one the code won't produce any results.
 
d


From: amibroker@xxxxxxxxxxxxxxx [mailto:amibroker@xxxxxxxxxxxxxxx] On Behalf Of soundscribe_studios
Sent: Saturday, May 27, 2006 6:56 PM
To: amibroker@xxxxxxxxxxxxxxx
Subject: [amibroker] Re: Problem with using "function" in AFL

Your suggestion put my on the right track to figuring it out. I think
the problem has something to do with variable scoping. I was
referencing "Buy_cond1" outside of the function first, making it global.

To make it work, I removed the reference to Buy_cond1 outside the
function and changed the call to

Buy_cond1 = rule1(a,b,c,d);

and it works as expected. I'm not clear on why it doesn't work in a
procedure, but is still probably scoping.

Thanks for the mental jog! I've been playing with this for hours.






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 other support material please check also:
http://www.amibroker.com/support.html





SPONSORED LINKS
Investment management software Real estate investment software Investment property software
Software support Real estate investment analysis software Investment software


YAHOO! GROUPS LINKS