Display Field: Line Breaks

The DISPLAY field for a menu item allows for some crafty formatting. The one I have yet to figure out (read a lot of postings in the forums) is how to simply put the COUNT value under the Menu Name.

On a mobile device with a specific width of display, the long text seems to wrap ideally, but not in every use case. 

JJ_TechSupport_0-1671239251445.png

CURRENT CODE

 

CONCATENATE("Everyone (",COUNT(FILTER("People",ISNOTBLANK([FIRST_NAME])))+COUNT(FILTER("People",ISNOTBLANK([MATE]))),")")

 

DESIRED CODE (a method to insert a "Line Feed")

 

CONCATENATE("Everyone",{LineFeed},"(",COUNT(FILTER("People",ISNOTBLANK([FIRST_NAME])))+COUNT(FILTER("People",ISNOTBLANK([MATE]))),")")

 

TEST CODE & RESULTS

Thinking AppSheet expressions might follow JavaScript syntax, I first tried using "\n" and "\r". And while both of these methods PASS expression testing, they fail to produce the desired outcome.

 

CONCATENATE("Everyone","\n(",COUNT(FILTER("People",ISNOTBLANK([FIRST_NAME])))+COUNT(FILTER("People",ISNOTBLANK([MATE]))),")")

 

JJ_TechSupport_1-1671239891723.png

 

CONCATENATE("Everyone","\r(",COUNT(FILTER("People",ISNOTBLANK([FIRST_NAME])))+COUNT(FILTER("People",ISNOTBLANK([MATE]))),")")

 

 JJ_TechSupport_2-1671240586531.png

ALMOST WORKING PERFECTLY

Aside from the stray comma after the word "Everyone" -- I think using SPLIT() and specifying the "/" as my delimiter seems to work. 

 

SPLIT(CONCATENATE("Everyone/(",COUNT(FILTER("People",ISNOTBLANK([FIRST_NAME])))+COUNT(FILTER("People",ISNOTBLANK([MATE]))),")"),"/")

 

JJ_TechSupport_3-1671241171908.png

0 6 178
6 REPLIES 6

At first this looked like the right answer because the emulator displayed correctly. 

 

SUBSTITUTE(search_string,",","")

 

CODES & RESULTS

 

SUBSTITUTE(SPLIT(CONCATENATE("Jammers/(",SUM(People[JAMMERS]),")"),"/"),",","")

 

JJ_TechSupport_0-1671242205297.png

JJ_TechSupport_1-1671242226139.png

But unfortunately, launching the app in another browser and resizing the screen either reveals it failed -- or that the UI is responsive -- or both. So I am still looking for how to split text for menu items where an item count is included.

You can't.

Yeah -- bummer -- I think if I had a BADGE I could update, that would be preferred. 

A "BADGE" ?

Well I may be using an incorrect term, but the circles next to icons that hold number values. Like the BELL at the top of this page when you have new alerts. 

Not in Appsheet.

Top Labels in this Space