Changing the tab names of a tabbed panel via script

Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller

Post Reply
danielrr
Posts: 142
Joined: Mon Mar 04, 2013 4:03 pm

Changing the tab names of a tabbed panel via script

Post by danielrr » Sat Mar 08, 2014 2:58 pm

This is an easy one (hope not a silly one) How do you change the tab labels of a tabbed-panel button via script?

Something like:

Code: Select all

set the tabs of btn "foo" to labelsList
does nothing.
best,
Daniel

BvG
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 1239
Joined: Sat Apr 08, 2006 1:10 pm
Contact:

Re: Changing the tab names of a tabbed panel via script

Post by BvG » Sat Mar 08, 2014 3:02 pm

it's a bit weird, you have to set the text of the button to a list of lines:

set the text of button "tabs" to "entry 1" & return & "entry 2" & return & "entry 3"
Various teststacks and stuff:
http://bjoernke.com

Chat with other RunRev developers:
chat.freenode.net:6666 #livecode

danielrr
Posts: 142
Joined: Mon Mar 04, 2013 4:03 pm

Re: Changing the tab names of a tabbed panel via script

Post by danielrr » Sat Mar 08, 2014 3:34 pm

Yes!! it works. Thanks Björnke

Post Reply