PureBytes Links
Trading Reference Links
|
Thanks to post by Tomasz in another thread where he mentioned
Status("action"), the significance of which I had missed, we
can now make the watchlist erase function work universally ie
when the code is included in an Indicator.
The amended code is as follows:
// clean up watchlists before starting
s = 0;
Actn = 0;
if(Actn = Status("action") == 4)
{
if( s = Status("stocknum") == 0 )
{
wlnumber =
CategoryFind("wlUsualSuspectsLongFilter",categoryWatchlist );
List = CategoryGetSymbols (categoryWatchlist, wlnumber);
for(i = 0; (Symbol = StrExtract(List, i)) != ""; i++)
{
CategoryRemoveSymbol (Symbol,categoryWatchlist, wlnumber);
}
}
}
Ian
--- In amibroker@xxxxxxxxxxxxxxx, "murthysuresh" <money@xxx>
wrote:
>
> thanks dingo for clearing it.
> Seede
> --- In amibroker@xxxxxxxxxxxxxxx, "dingo" <dingo@> wrote:
> >
> > It's a counter supplied by AB for the set of tickers you
are
> reading. The
> > first one will = 0 and so on.
> >
> > It's a way for you to identify the very first ticker and
therefore
> be able
> > to do some one-time stuff at the beginning of the run and
do it
> only once.
> >
> > d
> >
> > > -----Original Message-----
> > > From: amibroker@xxxxxxxxxxxxxxx
> > > [mailto:amibroker@xxxxxxxxxxxxxxx] On Behalf Of
murthysuresh
> > > Sent: Tuesday, September 04, 2007 2:27 PM
> > > To: amibroker@xxxxxxxxxxxxxxx
> > > Subject: [amibroker] Re: pl clarify what stocknum == 0
> > >
> > > What symbol is stocknum with status = 0. Is is a default
symbol
> that
> > > is never used by my scan except first time?
> > >
> > >
> > > --- In amibroker@xxxxxxxxxxxxxxx, "dingo" <dingo@> wrote:
> > > >
> > > > What guarantees it? The definition of
Status("Stocknum").
> > > >
> > > > d
> > > >
> > > > > -----Original Message-----
> > > > > From: amibroker@xxxxxxxxxxxxxxx
> > > > > [mailto:amibroker@xxxxxxxxxxxxxxx] On Behalf Of
murthysuresh
> > > > > Sent: Tuesday, September 04, 2007 9:19 AM
> > > > > To: amibroker@xxxxxxxxxxxxxxx
> > > > > Subject: [amibroker] pl clarify what stocknum == 0
> > > > >
> > > > > I am trying to understand the logic behind this
watchlist
> cleanup
> > > > > routine. what is this symbol that has
Status("stocknum") == 0
> > > > >
> > > > > what guarantees that it will be true only for the
first time
> > > > > during the
> > > > > exploration?
> > > > >
> > > > >
> > > > > // clean up watchlists before starting
> > > > > if( s = Status("stocknum") == 0 )
> > > > > {
> > > > > wlnumber = CategoryFind("wlUsualSuspectsLongFilter",
> > > > > categoryWatchlist );
> > > > > List = CategoryGetSymbols (categoryWatchlist,
wlnumber);
> > > > > for(i = 0; (Symbol = StrExtract(List,
i)) != ""; i++)
> > > > > {
> > > > > CategoryRemoveSymbol (Symbol,
> > > > > categoryWatchlist, wlnumber);
> > > > > }
> > > > > }
> > > > >
> > > > >
> > > > >
> > > > > 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
> > > > >
> > > > >
> > > > >
> > > > >
> > > >
> > >
> > >
> > >
> > >
> > > 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
> > >
> > >
> > >
> > >
> >
>
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/
|