LB() внутри OnQuote неккоректно отображает количество лотов. Подскажите, как правильно получать текущей остаток по бумагам в OnQuote?
| Код |
|---|
function LB()
n = getNumberOf("depo_limits")
value = 0
res = nil
for y = 0, n-1 do
trade = getItem("depo_limits", y)
res = trade.currentbal
end
return res
end
function OnQuote(CLASS, SEC)
...
if LB()==0 then
MakeOrderBuy()
end
if LB()==1 then
MakeOrderSell()
end
end
end |