Highlighted

Print When with two conditions

Explorer ,
Jul 09, 2014

Copy link to clipboard

Copied

I only want to print a page if two conditions are met. On each section I am using the following Print When Condition:

DateFormat(query.asofdate, "mm/dd/yyyy") NEQ DateFormat(calc.AmtDate, "mm/dd/yyyy")  AND LSNumberFormat((query.bal + calc.anticipated), "_.__") LTE LSNumberFormat(25.00, "_.__").

The date check works great by itself and the amount check works great by itself but I can't get them to work together. Any ideas?

I am using CF10.

TOPICS
Reporting

Views

320

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more

Print When with two conditions

Explorer ,
Jul 09, 2014

Copy link to clipboard

Copied

I only want to print a page if two conditions are met. On each section I am using the following Print When Condition:

DateFormat(query.asofdate, "mm/dd/yyyy") NEQ DateFormat(calc.AmtDate, "mm/dd/yyyy")  AND LSNumberFormat((query.bal + calc.anticipated), "_.__") LTE LSNumberFormat(25.00, "_.__").

The date check works great by itself and the amount check works great by itself but I can't get them to work together. Any ideas?

I am using CF10.

TOPICS
Reporting

Views

321

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Jul 09, 2014 0
Advocate ,
Jul 10, 2014

Copy link to clipboard

Copied

If the field types are explicit, then you don't need to format them as strings before comparing them.

What happens if you try the following expression?:

( (query.asofdate NEQ calc.AmtDate) AND (query.bal + calc.anticipated LTE 25.00) )

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jul 10, 2014 0
Explorer ,
Jul 11, 2014

Copy link to clipboard

Copied

That fixed the problem Thanks!

Is there anyway I can apply this to the whole page and not have to add it to every sections 'Print When Condition'?

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jul 11, 2014 0
Advocate ,
Jul 14, 2014

Copy link to clipboard

Copied

Cozmo2 wrote:

That fixed the problem Thanks!

Is there anyway I can apply this to the whole page and not have to add it to every sections 'Print When Condition'?

One way would be to exclude records that meet those conditions. That way you would not need to take them into account in your report.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jul 14, 2014 0