grandMA3 User Manual Publication
GetScreenContent(handle)
grandMA3 User Manual » Plugins » Lua Functions - Object-Free API » GetScreenContent(handle)
Version 2.0

Description

The GetScreenContent Lua function returns a handle to the screen content based on a provided handle to a screen configuration.

Arguments

  • Handle:
    This must be a handle to a screen configuration.

Return

  • Handle:
    The returned handle to the screen content.

Example

This example prints the data connected to the screen content handle. It uses the CurrentScreenConfig() and Dump() functions:

The CurrentScreenConfig Lua function returns a handle to the current users' screen configuration. Learn more in the CurrentScreenConfig topic.

Dump()

The Dump() function returns a string with information about the object, for instance, the name, class, path of the object, its properties, and children.

Learn more in the Dump() topic.

Lua
return function()
-- Create a handle for the current screen configuration.
local myCurrentScreenConfig = CurrentScreenConfig()
-- Create a handle for the screen content based on the screen configuration.
local myScreenContent = GetScreenContent(myCurrentScreenConfig)
-- Print the Dump of the handle.
Printf("=============== START OF DUMP ===============")
myScreenContent:Dump()
Printf("================ END OF DUMP ================")
end