PresetDocView:IsLastPresetRowSelected

From Moving Light Assistant
Jump to: navigation, search

IsLastPresetRowSelected()

Returns a boolean.

Available in MLA v1.3 onwards.

This function will return true if the last preset is selected in the preset list, otherwise will return false. Useful when iterating through the preset list.

Example.

PresetDocView:DispatchAction("Select First Preset")
presetListFinished = false
while presetListFinished == false do
-- Insert code here to do what you want with the preset.
-- Continue to next preset, or are we done.
if PresetDocView:IsLastPresetRowSelected() == true then
presetListFinished = true
else
PresetDocView:DispatchAction("Select Next Preset")
end
end

This select the first preset in the preset list and step through all the displayed presets.