Start a new topic

How do I create a simple LUA app to add a new layer?

Please use the following code to create a layer named "Border_Info", Red, Visible, with Layer Type "Fab Drawing":

mylayer = fab3000.dbLayer()
mylayer:setName("Border_Info")
mylayer:setType(fab3000.dbcLayerTypeFab)
mylayer:setVisible(1)
nMyLayerColor = fab3000.ColortoInt( 255, 0, 0 )
mylayer:setDrawColor( nMyLayerColor )
mylayer:setFlashColor( nMyLayerColor )
fab3000.dbAddLayer( mylayer )



Note:  Place the above into a text file with a LUA extension (*.lua) and then run the App - menu:  Applications / Run App...

Login or Signup to post a comment