Reply To: Patch Name to uiCDLabel

Home Forums General Programming Patch Name to uiCDLabel Reply To: Patch Name to uiCDLabel

#13082
lfo2vco
lfo2vco
Participant
  • Topics: 19
  • Replies: 133
  • Total: 152
  • ★★

Thanks Atom, still found it a struggle but got there in the end with:

nameData = midiMessage:getData():getRange(1,138)
nameRange = nameData:getRange(7,23)
nameLabel = panel:getComponent("Patch Label")

console (nameRange:getRange(2,16):toString())

if nameLabel ~= nil then 
    	nameLabel:setProperty ("uiLabelText", (nameRange:getRange(2,16):toString()), false)

	end

end

What I didn’t realise was that I could put (nameRange:getRange(2,16):toString()) where you had “myText”. That’s down to my very limited knowledge of Lua and coding in general.

Do NOT follow this link or you will be banned from the site!