[JW Lua] SetMeasurement

Chris marcel.denio at gmail.com
Thu Apr 23 16:29:41 CEST 2015


Hello Jari

I have a problem with this script.
The return value is a integer (1  instead of 1.76388)
Is it a problem of international decimal symbol ?

(sorry for my english)

---------------------------------
function EVPUtoCm(value)
     local string = finale.FCString()
     string:SetMeasurement(value, finale.MEASUREMENTUNIT_CENTIMETERS)
     return string.LuaString
end

local dialog = finenv.UserValueInput()
dialog.Title = "Test"
dialog:SetTypes("Number")
dialog:SetDescriptions("Variable")

local varEVPU = 200
local varCm = EVPUtoCm(varEVPU)
print(varCm)
dialog:SetInitValues(varCm)

returnValues = dialog:Execute()
if not returnValues then return false end
print(returnValues[1])
---------------------------------


Best regards

Chris




More information about the JWLua mailing list