Skip to main content

Search

Search

Vb Script To Terminate A Batch

Comments

2 comments

  • Avatar
    Domingo Rodriguez
    Moderator

    There is a VBScript function which you could make use of which is called Format.CancelPrinting(). However, I'm not sure if this will just cancel the current label being printed, or if this will cancel the pending batch of BT documents to be printed. In the worst case scenario, you could use Format.CancelPrinting() conditionally on every BT document.

     

    You can find further help on this function in BarTender's Help (F1 key) under the "Visual Basic Scripting > Scripting Objects > Object Reference > Format Object > Format Functions" topic.

    0
  • Avatar
    Legacy Poster

    Thanks for the reply.

    I use Format.CancelPrinting() already when the script identifies a product that doesn't require a particular label. This works fine but in this case I was trying to stop the batch executing any further label prints when a certain condition is true. Though I did read through the VB script help as suggested and didn't realise I could eliminate the Continue option Format.CancelPrinting() object - which is an improvement.  Nothing on terminating the batch though but I suspected this would be the case. I'll re-look at the job and see if there is another way to deal with it.

     

    Thanks again,

    Andrew

    0

Please sign in to leave a comment.