How to get a total count to show on a group tab

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: Klaus, FourthWorld, heatherlaine, kevinmiller

Post Reply
dandun
Posts: 24
Joined: Thu Apr 10, 2014 3:41 pm

How to get a total count to show on a group tab

Post by dandun » Tue Aug 12, 2014 5:08 pm

Greetings,

I am looking for a point in the right direction for how I can create a group tabbed button that will show a total count.

I am already familiar with how to create a group tab layout but not sure how to show a total count on that button.

In this example the three tabs will have a separate datagrid list. I am trying to get a way to represent the total count of each of these datagrids on the corresponding button itself.

Thanks in advance!
Dan
Attachments
tabbed counts.jpg

Klaus
Posts: 11197
Joined: Sat Apr 08, 2006 8:41 am
Location: Germany
Contact:

Re: How to get a total count to show on a group tab

Post by Klaus » Tue Aug 12, 2014 5:26 pm

Hi Dan,

what is a "group tab layout"? :shock:

Whatever, you can set "the label" of a button to multiline-text if neccessary:
...
## Fill tScore with whatever you need:
put 10 into tScore
set the label of btn "your button here" to tScore & CR & "This is line 2 of 2"
...

Best

Klaus

dunbarx
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 6160
Joined: Wed May 06, 2009 2:28 pm
Location: New York, NY

Re: How to get a total count to show on a group tab

Post by dunbarx » Tue Aug 12, 2014 5:57 pm

Dan.

Is that what you meant by a "group tab layout", a few buttons arranged in a row along with some other bounding control?

Is the issue that you cannot have a multi-line entry in a tabbed button? This is in fact true, and hence Klaus' comment that you can have a multi-line label in an ordinary button.

Craig Newman

dandun
Posts: 24
Joined: Thu Apr 10, 2014 3:41 pm

Re: How to get a total count to show on a group tab

Post by dandun » Tue Aug 12, 2014 7:57 pm

Sorry for the confusion. I was referring to a custom tab button that consists of one group and a few buttons. But it sounds like Klaus did answer my question on how to add the count. I will give it a try.
Thank you

Klaus
Posts: 11197
Joined: Sat Apr 08, 2006 8:41 am
Location: Germany
Contact:

Re: How to get a total count to show on a group tab

Post by Klaus » Wed Aug 13, 2014 12:40 pm

Adding and using some extra transparent fields instaed of buttons might also do the job :D

Post Reply

Return to “Getting Started with LiveCode - Complete Beginners”