Arturia Keylab : display on LCD screen

This is the script I am using. Updated from the script from @TicoRicoRay

Updated to show songs in setlist, and added Callback since Variations weren’t catching mouse clicks to rack space changes.

//Global Rackspace must have a MIDI OUT Plugin with the handle KeyLab88MIDIOut
var KeyLab88MIDIOut : MidiOutBlock

//Send Keylab LCD Sysex Message
Function KeylabLCD(line1 : String, line2 : String)
    var 
        KEYLAB_LCD_PRE : String = "F0 00 20 6B 7F 42 04 00 60 01 "
        KEYLAB_LCD_SEP : String = "00 02 "
        KEYLAB_LCD_END : String ="00 F7"
        msg : SysexMessage = 
            KEYLAB_LCD_PRE 
            + StringToHexString(CopySubstring(line1,0,16)) 
            + KEYLAB_LCD_SEP 
            + StringToHexString(CopySubstring(line2,0,16)) 
            + KEYLAB_LCD_END
    
    SendSysexExternal(KeyLab88MIDIOut, msg)
End

//Update LCD
Function UpdateLCD()
    If InSetlistMode() Then
        KeylabLCD(GetCurrentSongName(), GetCurrentSongPartName())
    Else
        KeylabLCD(GetRackspaceNameAtIndex(GetCurrentRackspaceIndex()), GetVariationName(GetCurrentVariation()))
    End
End

//Callbacks
On Variation(old : Integer, new : Integer)
    UpdateLCD()
End

On Rackspace(old : Integer, new : Integer)
    UpdateLCD()
End