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: 
Anonymous
Not applicable

Date in Label Nprinting

hi,

i want to insert a function:

date( today()-2 , 'dd MMMM yyyy' )

in  PixelPerfect label. It's possibile?

i've .qvw source also and i just create same expression as variable vToday.

How can i use it in a Label ?

Thank you

1 Solution

Accepted Solutions
Ruggero_Piccoli
Support
Support

Hi,

Use this formula instead:

=text(date( today()-2 , 'dd MMMM yyyy' ))

text() will force the output to be a string so PixelPerfect will interpret it correctly.

Best Regards,

Ruggero

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

When applicable please mark the appropriate replies as CORRECT. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads as HELPFUL if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads as HELPFUL if you feel additional info is useful to others.



Best Regards,
Ruggero
---------------------------------------------
When applicable please mark the appropriate replies as CORRECT. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads with a LIKE if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads with LIKEs if you feel additional info is useful to others.

View solution in original post

6 Replies
Ruggero_Piccoli
Support
Support

Add it into the Variables node, then drag and drop into the template.

Best Regards,

Ruggero

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

When applicable please mark the appropriate replies as CORRECT. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads as HELPFUL if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads as HELPFUL if you feel additional info is useful to others.



Best Regards,
Ruggero
---------------------------------------------
When applicable please mark the appropriate replies as CORRECT. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads with a LIKE if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads with LIKEs if you feel additional info is useful to others.
Anonymous
Not applicable
Author

It dosen't works 'cause it display only a formula (expression)

Stephen_Jasionowski

Did you bind the formula/variable to the label object?

Lech_Miszkiewicz

it is because you want your date to evaluate before beeing pass to template

If it is in variable - put  "=" sign before your expression, or use the same on template level and create NPrinting formula instead.

cheers

Lech

cheers Lech, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful to the problem.
Ruggero_Piccoli
Support
Support

Hi,

Use this formula instead:

=text(date( today()-2 , 'dd MMMM yyyy' ))

text() will force the output to be a string so PixelPerfect will interpret it correctly.

Best Regards,

Ruggero

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

When applicable please mark the appropriate replies as CORRECT. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads as HELPFUL if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads as HELPFUL if you feel additional info is useful to others.



Best Regards,
Ruggero
---------------------------------------------
When applicable please mark the appropriate replies as CORRECT. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads with a LIKE if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads with LIKEs if you feel additional info is useful to others.
Anonymous
Not applicable
Author

Grazie Ruggero

It works!