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

[amibroker] Re: Any way to retrieve AA filter settings programmatically?



PureBytes Links

Trading Reference Links



Dave,

I'm not aware of any function call that will give you what you are after. That being the case, the safest thing to do might be to add a parameter to your code, then set the parameter from the AA window (using Parameters button) before running the exploration. You will still need to set the watchlist in the Filter area too.

If for some reason you don't want to do that, then you can access the COM object for the Analysis window and ask it which watchlist it has set in its Filter property. This does work, but it is bad practice since you should not be accessing the very object that is currently running. Also, it may continually force the AA window to open. If you go this route, don't expect any help from support ;)

Code sample for both approaches is as follows:

/*
function getWatchlist() {
   ab = CreateObject("Broker.Application");
   aa = ab.Analysis;
   return aa.Filter(0, "watchlist");
}

_TRACE("Watchlist is: " + getWatchlist());
*/


watchlist =
Param( "Watchlist", 0
);
_TRACE( "Watchlist is: "
+ watchlist );

Buy = Sell = Cover = Short = 0
;
Filter = 1
;
AddColumn( 0, "Dummy" );

Mike


--- In amibroker@xxxxxxxxxxxxxxx, "davidanaumann" <davidanaumann@xxx> wrote:
>
> If possible I'd like to run some explorations on a watchlist of symbols. In the AA filter settings I choose the watchlist I'd like to explore. Then within my afl I need access to that list of symbols. I know I can get a comma delimited list of symbols by calling CategoryGetSymbols(), but the problem is I don't know which watchlist is set in the filters setting. Does anyone know how I might get at this info from afl? Thanks in advance!
>
> Dave
>



__._,_.___


**** IMPORTANT PLEASE READ ****
This group is for the discussion between users only.
This is *NOT* technical support channel.

TO GET TECHNICAL SUPPORT send an e-mail directly to
SUPPORT {at} amibroker.com

TO SUBMIT SUGGESTIONS please use FEEDBACK CENTER at
http://www.amibroker.com/feedback/
(submissions sent via other channels won't be considered)

For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/





Your email settings: Individual Email|Traditional
Change settings via the Web (Yahoo! ID required)
Change settings via email: Switch delivery to Daily Digest | Switch to Fully Featured
Visit Your Group | Yahoo! Groups Terms of Use | Unsubscribe

__,_._,___