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

Re: [amibroker] Re: How to use watchlistbits?



PureBytes Links

Trading Reference Links

ty!
----- Original Message ----- 
From: "Tomasz Janeczko" <groups@xxxxxxxxxxxxx>
To: <amibroker@xxxxxxxxxxxxxxx>
Sent: Saturday, June 24, 2006 5:50 AM
Subject: [amibroker] Re: How to use watchlistbits?


> Hello,
> 
> WatchListBits and WatchListBits2 is a bit array so you should use 
> 
> (in JScript):
> 
> WListNumber = 15;
> 
> if( WListNumber < 32 )
>  st.WatchListBits = st.WatchListBits | ( 1 << WListNumber);
> else
>  st.WatchListBits2 = st.WatchListBits2 | ( 1 << (WListNumber-32));
> 
> 
> BUT....
> in AFL there is a lot more comfortable way using CategoryAddSymbol:
> www.amibroker.com/f?categoryaddsymbol
> 
> 
> CategoryAddSymbol( "", categoryWatchlist, WListNumber ); 
> 
> Regards,
> Tomasz Janeczko
> amibroker.com
> 
> --- In amibroker@xxxxxxxxxxxxxxx, "cstrader232" <cstrader232@xxx> 
> wrote:
>>
>> I could use some help with watchlist bits: 
>> 
>> I get the syntax for adding a stock, and deleting it:
>> 
>> AB = CreateObject("Broker.Application");
>> 
>> st = AB.Stocks;
>> 
>> st.Remove("QQQQ"); 
>> 
>> st.Add("QQQQ");
>> 
>> 
>> 
>> But how do I add the stock to a watchlist?  
>> 
>> ???
>> 
>> st.WatchListBits | ( 1 << 1);
>> 
>> 
>> tia!
>>
> 
> 
> 
> 
> 
> 
> 
> 
> 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
> 
> 
> Yahoo! Groups Links
> 
> 
> 
> 
> 
>