How can i hide certain value in automated PDF document

Hello, i'm making an app for the employees to log in their work duration and the data will be automated into PDF files.

My issue is with the PDF document created. Is there a way i can only show the TOTALHOURS calculated when there is start_time & end_time entered into the field?

As you can see here, when theres NO start_time & end_time inserted, the totalhours will return as 0.00 and hence it will be automatically inserted into the PDF document. 

TOTALHOURS Visibility.png

 

 





This is the TOTALHOURS expression i use.
_________

template bikswp2.png

 

 

 

 





This is the automated PDF document created. 
If the TOTALHOURS returns as 0.00, i plan to hide it in the automated PDF document.

Is there a way i can hide the TOTALHOURS in the PDF document when it returns as 0.00?

Solved Solved
0 12 280
2 ACCEPTED SOLUTIONS

In the PDF template, for the table data you are likely using some list OR expression to choose the rows to be included.  Use an expression that chooses the data rows meeting your required criteria to be shown.  

If you show us the template expression you are using we can help update it.

View solution in original post

<<IF(
AND(
ISNOTBLANK([Start Time]),
  ISNOTBLANK([End Time])
),
[Total Hours],
""
)>>

 Simon, 1minManager.com

View solution in original post

12 REPLIES 12

In the PDF template, for the table data you are likely using some list OR expression to choose the rows to be included.  Use an expression that chooses the data rows meeting your required criteria to be shown.  

If you show us the template expression you are using we can help update it.

Im using the TOTALHOURS() expression for the rows returning as 0.00 (in the pdf template) when theres no data input into it:

TOTALHOURS([JAM TAMAT_1]-[JAM MULA_1])

And the column type is: decimal

What is the expression i can use to return the value of 0.00 as blank or to hide it in the PDF template?


I'm sorry sir, i misunderstood your explanation. Im a newbie & didnt know earlier that i can put an expression in the PDF TEMPLATE itself.  By using the expression given by @1minManager , i able to solve the problem. Thanks thanks a LOT for the help!

<<IF(
AND(
ISNOTBLANK([Start Time]),
  ISNOTBLANK([End Time])
),
[Total Hours],
""
)>>

 Simon, 1minManager.com

Hello, thanks for the suggestion. Ive tried this formula by creating an extra virtual column. But the issue is the Column Type of the virtual column is restricted to decimal. Thus the form cant be save when i put the return value as: " ". 

I've also tried adjusting it a bit by putting a dot:
IF(
AND(
ISNOTBLANK([JAM MULA_4]),
ISNOTBLANK([JAM TAMAT_4])
),
[_ComputeTotalJam4],
"."
)

But also to no avail. The problem is the column type is using decimal so it reject the value when its empty or when i use a dot in it. Any ideas to solve this issues?

To set a column of type Decimal to blank, use DECIMAL("").

thanks a lot for the help

Thanks alot, this actually solve the problem. I misunderstood earlier i thought this should be use in the virtual column. I'm a newbie a didnt know that expression can be use in the pdf template. 

I've changed the expression in the pdf template itself and the expression you provide solves the problem. THANKS A LOT.

Can you share a screenshot of the template and it's expressions?

I didnt know earlier that i can put the expression in the pdf template itself. Im a newbie here and this community taught me a lot. Heres the pdf template and by using the expression given by 1minmanager i able to solve the issue

pdf template solve.png

Specify it explicitly in the template that you don't want 0 values, like:

FILTER(table, AND(ISNOTBLANK([JAM]), NOT([JAM] = 0)))

Interesting, this is another way how i can use the expression to achieve whats intended. Im very new and didnt know the ins and out of appsheet well. Thanks a lot for the help. Will try this out also. 

Top Labels in this Space