Cancel printing for only certain records via VBScript? 追蹤

0
Avatar
Matt Brooks

BT 10.1

This works at doc level VBScript OnNewRecord:

If Field("DB.NAME") = "JAMES" Then

Format.CancelPrinting()

End If

Problem is, it cancels the entire print job. I need only records that have NAME = JAMES to cancel. I need the evaluation made on a per record basis and the cancelprinting command also only for that record.

Can this be done?

2 意見

0
Avatar
Shotaro Ito
評論操作 永久連結

You can specify Query in database setup,
Such as to print
NAME is not equal to "JAMES"

In Automation edition, you have print condition in template - you can specify to not print if specific condition is met
From Page setup > Template tab.
(print condition is not available in Professional edition.)

0
Avatar
Matt Brooks
評論操作 永久連結

Shotaro, thanks! I had completely forgotten about that feature. I think I am even using it on some template I created years back, thanks :)

登入寫評論。