locked
Hide Label and Text if Empty RRS feed

  • Question

  • I have this basic formula that adds "Tel:" to the beginning of the text but I want to hide Tel: and the number if it's empty. How can I modify it to do this?

    ="Tel:" & Fields!nphone.Value

    Thanks!

    Wednesday, July 8, 2020 3:40 PM

Answers

  • That was the reason for my original question.

    Try

    =IIF(Fields!nphone.Value Is Nothing or Fields!nphone.Value=="","","Tel:" &Fields!nphone.Value)  


    For every expert, there is an equal and opposite expert. - Becker's Law


    My blog


    My TechNet articles


    • Edited by Naomi N Wednesday, July 8, 2020 5:42 PM
    • Marked as answer by VrRotateTX Wednesday, July 8, 2020 5:47 PM
    Wednesday, July 8, 2020 5:42 PM

All replies

  • Is it coming as NULL or empty string?

    Try 

    =IIF(Fields!nphone.Value Is Nothing,"","Tel:" &Fields!nphone.Value)  


    For every expert, there is an equal and opposite expert. - Becker's Law


    My blog


    My TechNet articles

    Wednesday, July 8, 2020 5:13 PM
  • So that still put "Tel: " on every line even if nphone was blank.
    Wednesday, July 8, 2020 5:27 PM
  • That was the reason for my original question.

    Try

    =IIF(Fields!nphone.Value Is Nothing or Fields!nphone.Value=="","","Tel:" &Fields!nphone.Value)  


    For every expert, there is an equal and opposite expert. - Becker's Law


    My blog


    My TechNet articles


    • Edited by Naomi N Wednesday, July 8, 2020 5:42 PM
    • Marked as answer by VrRotateTX Wednesday, July 8, 2020 5:47 PM
    Wednesday, July 8, 2020 5:42 PM
  • That did it! Thank you!
    Wednesday, July 8, 2020 5:47 PM