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

[amibroker] Re: Force VBscript variable to array, not scalar



PureBytes Links

Trading Reference Links

Never mind, figured it out.

The first instantiation of the var in my script treated it as a 
scalar so the rest of the code treated it as a scalar.

HB

--- In amibroker@xxxxxxxxxxxxxxx, "hmab1" <hossamb@xxxx> wrote:
> Hello,
> 
> My vbscript code keeps converting an AFL variable to a scalar.  How 
> do I force it to maintain the var as an array ?
> 
> Code with error follows.  The buyarray var is always a scalar while 
I 
> would like it be an array.
> 
> /////////////
> potentialbuy = Buy OR (BarsSince(Buy) < 6);
> EnableScript("vbscript");
> <%
>   buyarray = AFL("potentialbuy")
>   MsgBox "Last value is " & buyarray(UBound(buyarray))
> %>
> /////////////
> 
> Thanks,
> HB


------------------------ Yahoo! Groups Sponsor ---------------------~-->
Get A Free Psychic Reading! Your Online Answer To Life's Important Questions.
http://us.click.yahoo.com/Lj3uPC/Me7FAA/ySSFAA/GHeqlB/TM
---------------------------------------------------------------------~->

Send BUG REPORTS to bugs@xxxxxxxxxxxxx
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx 
(Web page: http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.html 

Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/