Showing results for 
Search instead for 
Did you mean: 
Helper I
Helper I

Hiding Fields with no data in an email report

Hello, I previously posted about sending an email when a record is updated, and it is working well; however, I would like to have the end email "hide" any entries in the SharePoint List that are Blank (This gets sent company wide and I don't want all the unused fields shown). Thank you for your help and time! Here is the code, and an output image.


Back(); Set(newRecord, EditForm1.LastSubmit);
	"Update for Lot",
	"Lot #: "& newRecord.'Lot #'& Char(10)&
	"MBR #: "& newRecord.'MBR Number' & Char(10)&
	"Formulation WO: "& newRecord.'Formulation WO'& Char(10)&
	"Filling WO: "& newRecord.'Filling WO'& Char(10)&
	"Buffer Start: "& newRecord.'Buffer Start'& Char(10)&
	"Buffer End: "& newRecord.'Buffer End'& Char(10)&
	"Thaw/Equilibration Start: "& newRecord.'Thaw Start'& Char(10)&
	"Thaw/Equilibration End: "& newRecord.'Thaw End'& Char(10)&
	"WFI Addition Start: "& newRecord.'WFI Addition Start'& Char(10)&
	"WFI Addition End: "& newRecord.'WFI Addition End'& Char(10)&
	"Formulation Start: "& newRecord.'Formulation Start'& Char(10)&
	"Formulation End: "& newRecord.'Formulation End'& Char(10)&
	"API Addition Start: "& newRecord.'API Addition Start'& Char(10)&
	"API Addition End: "& newRecord.'API Addition End'& Char(10)&
	"Pooling Start: "& newRecord.'Pooling Start'& Char(10)&
	"Pooling End: "& newRecord.'Pooling End'& Char(10)&
	"Dilution Start: "& newRecord.'Dilution Start'& Char(10)&
	"Dilution End: " & newRecord.'Dilution End'& Char(10)&
	"BBR Filtration Start: "& newRecord.'BBR Filtration Start'& Char(10)&
	"BBR Filtration End: "& newRecord.'BBR Filtration End'& Char(10)&
	"Sterile Filtration Start: "& newRecord.'Sterile Filtration Start'& Char(10)&
	"Sterile Filtration End: "& newRecord.'Sterile Filtration End'& Char(10)&
	"Filling Start: "& newRecord.'Filling Start'& Char(10)&
	"Filling End: "& newRecord.'Filling End'& Char(10)&
	"Lyo Unload Start: "& newRecord.'Lyo Unload Start'& Char(10)&
	"Lyo Unload End: "& newRecord.'Lyo Unload End'& Char(10)&
	"1C Test Result: "& newRecord.'1C' & " "& newRecord.'1C Unit' & Char(10)&
	"2C Test Result: "& newRecord.'2C' & " "& newRecord.'2C Unit' & Char(10)&
	"3C Test Result: "& newRecord.'3C' & " "& newRecord.'3C Unit' & Char(10)&
	"4C Test Result: "& newRecord.'4C' & " "& newRecord.'4C Unit' & Char(10)&
	"5C Test Result: "& newRecord.'5C' & " "& newRecord.'5C Unit' & Char(10)&
	"6C Test Result: "& newRecord.'6C' & " "& newRecord.'6C Unit' & Char(10)&
	"1M Test Result: "& newRecord.'1M ' & " "& newRecord.'1M Unit' & Char(10)&
	"Endotoxin Test Result: "& newRecord.'Endotoxin Test Result' & Char(10)&
	"pH Test Result: "& newRecord.'pH Test Result' & Char(10)&
	"Pooled Weight: "& newRecord.'Pooled Weight' & "kg" & Char(10)&
	"BBR Filtered Weight: "& newRecord.'BBR Weight' & "kg" & Char(10)&
	"Steriel Filtered Weight: "& newRecord.'Sterile Weight' & "kg" & Char(10)&
	"Theoretical Yield: "& newRecord.'Theoretical Yield' & " Units" & Char(10)




Email Ex.JPG


Accepted Solutions

Saw your posts.  Did my idea work for you? 

View solution in original post

Super User III
Super User III


Great question!


You can take this line...

"Lot #: "& newRecord.'Lot #'& Char(10)&


...and change it to this code to show nothing when the value for Lot is blank.

If(!IsBlank(newRecord.'Lot #'), "Lot #: "& newRecord.'Lot #'& Char(10))&


Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."

Is there an additional True/False Statement needed for this? I'm getting an error

NVM, forgot the additional ) 

Saw your posts.  Did my idea work for you? 

View solution in original post

Helpful resources

PA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

MBAS Attendee Badge

Claim Your Badge & Digital Swag!

Check out how to claim yours today!


Demo Extravaganza is Back!

We are excited to announce that Demo Extravaganza for 2021 has started!

MBAS on Demand

Microsoft Business Applications Summit sessions

On-demand access to all the great content presented by the product teams and community members! #MSBizAppsSummit #CommunityRocks

Power Apps June 2021

June Power Apps Community Call

Don't miss the call this month on June 16th - 8a PDT

Top Solution Authors
Top Kudoed Authors
Users online (89,842)