День добрый! Подскажите знающие люди, правильно ли я пытаюсь получить параметры таблиц в переменные. Заранее спасибо.
local tblAsk = getParamEx(CLASS_CODE, SEC_CODE, "OFFER")
local tblBid = getParamEx(CLASS_CODE, SEC_CODE, "BID")
local tblStatus = getParamEx(CLASS_CODE, SEC_CODE, "STATUS")
local tblMinLot = getParamEx(CLASS_CODE, SEC_CODE, "LOTSIZE")
local tblBalance = getMoneyEx(FIRM_ID, CLIENT_CODE, TAG, CURR_CODE,LIMIT_KIND)
local tblTotalLot = getDepoEx(FIRM_ID, CLIENT_CODE, SEC_CODE, ACCOUNT ,LIMIT_KIND)
local tblMinStepPrice = getParamEx(CLASS_CODE, SEC_CODE, "SEC_PRICE_STEP")
if tblAsk==nil then Ask=0 else Ask=tonumber(tblAsk.param_value) end
if tblBid==nil then Bid=0 else Bid=tonumber(tblBid.param_value) end
if tblStatus==nil then Status=0 else Status=tonumber(tblStatus.param_value) end
if tblMinLot==nil then MinLot=0 else MinLot=tonumber(tblMinLot.param_value) end
if tblBalance==nil then Balance=0 else Balance=tonumber(tblBalance.currentbal) end
if tblTotalLot==nil then TotalLots=0 else TotalLots=tonumber(tblTotalLot.currentbal) end
if tblMinStepPrice==nil then MinStepPrice=0 else MinStepPrice=tonumber(tblMinStepPrice.param_value) end
local tblAsk = getParamEx(CLASS_CODE, SEC_CODE, "OFFER")
local tblBid = getParamEx(CLASS_CODE, SEC_CODE, "BID")
local tblStatus = getParamEx(CLASS_CODE, SEC_CODE, "STATUS")
local tblMinLot = getParamEx(CLASS_CODE, SEC_CODE, "LOTSIZE")
local tblBalance = getMoneyEx(FIRM_ID, CLIENT_CODE, TAG, CURR_CODE,LIMIT_KIND)
local tblTotalLot = getDepoEx(FIRM_ID, CLIENT_CODE, SEC_CODE, ACCOUNT ,LIMIT_KIND)
local tblMinStepPrice = getParamEx(CLASS_CODE, SEC_CODE, "SEC_PRICE_STEP")
if tblAsk==nil then Ask=0 else Ask=tonumber(tblAsk.param_value) end
if tblBid==nil then Bid=0 else Bid=tonumber(tblBid.param_value) end
if tblStatus==nil then Status=0 else Status=tonumber(tblStatus.param_value) end
if tblMinLot==nil then MinLot=0 else MinLot=tonumber(tblMinLot.param_value) end
if tblBalance==nil then Balance=0 else Balance=tonumber(tblBalance.currentbal) end
if tblTotalLot==nil then TotalLots=0 else TotalLots=tonumber(tblTotalLot.currentbal) end
if tblMinStepPrice==nil then MinStepPrice=0 else MinStepPrice=tonumber(tblMinStepPrice.param_value) end