Skip to main content
Announcements
Defect acknowledgement with Nprinting Engine May 2022 SR2, please READ HERE
cancel
Showing results for 
Search instead for 
Did you mean: 
mikecrengland
Creator III
Creator III

NPrinting / HTML Report / email body / formula question

Hello All -

I'm trying to create an HTML report to embed into the body of an email. So far so good, but I've run into a problem.

In the HTML report, I've created Formulas that will represent dates in the main report. An example is  =Date(Max(WeekStart),'MMM D')

Capture.PNG

I added it to the HTML:

<li>"Current" represents the week of %%Current%%

When I preview the report, it works great.

Capture2.PNG

But when I test the task, the email body shows:

  • "Current" represents the week of %%Current%%

Capture3.PNG

Why does it work in a browser, but not in the email distribution?

Thanks,

mike

1 Solution

Accepted Solutions
mikecrengland
Creator III
Creator III
Author

I had to do a couple of things to make this work and to get the look that I wanted.

  • First, I added {1} to the date Formulas in the HTML report. For whatever reason, the email body just wouldn't work without the set analysis, even though the preview of the report did.
  • I embedded the HTML report within an Html Text email body so that I could use some of the message tags instead of a Formula in the HTML report

View solution in original post

8 Replies
mikecrengland
Creator III
Creator III
Author

Any thoughts on this?

Stephen_Jasionowski

Mike -

I'm not sure why it's reverting back to a tag, but have you considered adding that text inside the email message? You can include QV variables in the subject line and message body. So if it is possible to separate that from the report, I'd try that. How to Include Dynamic Elements in NPrinting E-mail

mikecrengland
Creator III
Creator III
Author

Thanks, Stephen. I'll give that a try.

mikecrengland
Creator III
Creator III
Author

Is it possible to embed a hyperlink in the HTML Text format? Kind of like control-K in a MS Office document?

mikecrengland
Creator III
Creator III
Author

I had to do a couple of things to make this work and to get the look that I wanted.

  • First, I added {1} to the date Formulas in the HTML report. For whatever reason, the email body just wouldn't work without the set analysis, even though the preview of the report did.
  • I embedded the HTML report within an Html Text email body so that I could use some of the message tags instead of a Formula in the HTML report
alejo13qv
Contributor III
Contributor III

Hi Mike,

I am facing the same when designing the email body attempting to utilize created formulas in the report designer.

This is an excel report to be sent attached and each of the below has been treated as just text.

"Hi %%User_FullName%%,

The attached file contains Dashboards usage furing the past week between %%{1}PrvWk_Start%% and %%{1}PrvWk_End%%."

--------------------------------------------

"Hi %%User_FullName%%,

The attached file contains Dashboards usage furing the past week between %%PrvWk_Start%% and %%PrvWk_End%%."

--------------------------------------------

"Hi %%User_FullName%%,

The attached file contains Dashboards usage furing the past week between %%<PrvWk_Start>%% and %%<PrvWk_End>%%."

Could you please elaborate on how you embedded the text in the body?

thanks,

Alejandro

mikecrengland
Creator III
Creator III
Author

Hi Alejandro -

Before I spend too much time, I see the {1} in your variable name:

%%{1}PrvWk_Start%%

Is it also in your expression? Using the {1} in your set analysis makes the expression ignore any filters.

mike

alejo13qv
Contributor III
Contributor III

Hi Mike,

Thanks for the prompt response.

It is not in the formula expression, it is only present in the email body where I assumed you placed it, maybe I missunderstood you.

Formula_PrvWk_End.JPG

Alejandro