Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics NAV (Archived)

Reduce font size

Posted on by Microsoft Employee

Hi,

How can I change this to say, if there is greater then 9 letters, reduce the font size by 2, and again if theirs greater then 18 letters, reduce it by so many. 78.PNG

Thanks 

*This post is locked for comments

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Reduce font size

    There isn't a CHOOSE function available?

    iif (length(field) < 18, choose(length(field),24,24,24,24,24,24,24,24,24,20,22,20,18,16,14,12,10,8,6),6) or whatever the format is...

    would give finer control.

  • Verified answer
    Rajasekhar@MS Profile Picture
    Rajasekhar@MS 5,567 on at
    RE: Reduce font size

    Hi

    You can try below

    =iif(len(Fields!ProdOrderNo.Value)<9, "24pt", iif(len(Fields!ProdOrderNo.Value)<18, "16pt", "8pt"))

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Reduce font size

    Thanks again, unfortunately it doesn't appear to have worked.  

  • Suggested answer
    RE: Reduce font size
    =switch(
    	iif(len(Fields!ProdOrderNo.Value)<9, "24pt", "16pt"),
    	iif(len(Fields!ProdOrderNo.Value)<18, "24pt", "8pt")
    )

    Try this. By the way, do test, because I did not test it.

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Reduce font size

    Thank you that's very useful!

    This top line does work ..

    =iif(len(Fields!ProdOrderNo.Value)<9, "24pt", "16pt")

    How can I adjust this if it's possible to include..

    =iif(len(Fields!ProdOrderNo.Value)<18, "24pt", "8pt") but include it in one line as currently it doesn't pick up the second line.

  • Suggested answer
  • Suggested answer
    Amol Salvi Profile Picture
    Amol Salvi 18,694 on at
    RE: Reduce font size

    May be you can look at Font size expression

    Or

    You can create two text box and make it visible based on condition

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Reduce font size

    Is there any way of saying Every time there's a '/' reduce the font size?

  • Suggested answer
    Mohana Yadav Profile Picture
    Mohana Yadav 59,139 Super User 2024 Season 2 on at
    RE: Reduce font size

    I dont think it is possible

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,269 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,198 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans