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

[amibroker] Bugged out (2)



PureBytes Links

Trading Reference Links

Code:
-----
if (DateNum()==Status("rangefromdate") AND DateNum()==Status
("rangetodate"));
{
AddToComposite(V,"~TICKER1","V",16);

AddToComposite(IIf(C>Ref(C,-1),1,IIf(C<Ref(C,-1),-
1,0)),"~TICKER1","C",16);
}

NumHighest=15;
while (NumHighest>0)
{
NumHighest=NumHighest-1;
HoldValue=ValueWhen(Highest(Foreign("~TICKER1","V")),Foreign
("~TICKER1","C"),1);
AddToComposite(HoldValue,"~TICKER1","H",16);
}

AddColumn(V,"Volume",1.0);
AddColumn(C-Ref(C,-1),"Change");
AddColumn(IIf(C>Ref(C,-1),1,IIf(C<Ref(C,-1),-1,0)),"ChCount",1.0);
Filter=V>3000000;

Error:
-----
Line 3, Column 1:
if (DateNum()==Status("rangefromdate") AND DateNum()==Status
("rangetodate"));

{
^

Error 3.
Condition in IF, WHILE, FOR statements
has to be Numeric or Boolean type.
You can not use array here,
please use [] (array subscript operator)
to access array elements

In this the if statement seems to function, in that the V and C 
fields of ~TICKER1 are now correct.  I have speant hours on this and 
looking at examples which for the life of me I can't see as being any 
different.  I have tried many variations too with similar results.  
TO be honest, I don't know why this has any positive result while 
Bugged Out(1) does not.
S.O.S.
Rich


------------------------ Yahoo! Groups Sponsor ---------------------~-->
Get A Free Psychic Reading! Your Online Answer To Life's Important Questions.
http://us.click.yahoo.com/Lj3uPC/Me7FAA/CNxFAA/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/