Passing Query Values To Commander フォローする

0
Avatar
Legacy Poster

Firstly please forgive me if this is in the wrong place or a really stupid question, but I am very new to BarTender.

 

I have designed a label that pulls information from our manufacturing database for a particular 'Goods Receipt', whos number is set up as a prompt.

 

What I want to do is have commander scanning a directory in which I will create a file whenever goods are received. The file can contain the goods receipt number but how do I pass it to the print command.

 

Thanks in advance for any help people can offer.

 

 

7 コメント

0
Avatar
Legacy Poster
コメントアクション Permalink

This may help throw a little more light on my problem

 

/AF="C:\Users\ian.pike\Documents\BarTender\BarTender Documents\QR Coded label.btw" /PRN="MyPrinter" /P /D="%Trigger File Name%" /?GRN_NO#=<Trigger Contents>

 

Copied from the Command Parameter and this does not work.

 

/AF="C:\Users\ian.pike\Documents\BarTender\BarTender Documents\QR Coded label.btw" /PRN="MyPrinter" /P /D="%Trigger File Name%" /?GRN_NO#="GR/761632"

 

This does work.

 

When it fails I get a message in BarTender:-

 

BarTender: Error Message #3219

Invalid Join Condition for All Database Join

Database Text File 1 is missing from the Join

 

The lable uses on view in my database.

0
Avatar
Ian Cummings
モデレータ
コメントアクション Permalink

Is the trigger file supposed to contain any data to print on the label, or is it supposed to be just a command telling BarTender to open label format X, to print to printer Y, using data from database record Z?

 

If yes to the above question they you would use a Commander Script command and have something like this in your trigger file contents:

 

%BTW% /AF="C:\Users\ian.pike\Documents\BarTender\BarTender Documents\QR Coded label.btw" /PRN="MyPrinter" /P /?GRN_NO#="GR/761632"

%END%

 

Note that the only label data that the label will connect to is the fixed database.  In the Commander script you would specify the query prompt value in order to have BarTender find the matching record/s and print it/them.

 

See this white paper for more details: http://www.bartenderbarcodesoftware.com/label-software/whitepapers/Commander-Examples(English).pdf

0
Avatar
Legacy Poster
コメントアクション Permalink

Ian C,

 

I am trying to connect to an SQL database in my .btw file. Are you saying that I can not do that?

 

I have copied

%BTW% /AF="C:\Users\ian.pike\Documents\BarTender\BarTender Documents\QR Coded label.btw" /PRN="MyPrinter" /P /?GRN_NO#="GR/761632"

%END%

 

To my trigger file and changed the Command Type to Commander Script but it stillwaits for me to answer the Query prompt.

0
Avatar
Ian Cummings
モデレータ
コメントアクション Permalink

No I am not saying that.  Of course your BarTender document can connect to a fixed database, if that is what you want it to do.  However, if you want Commander to pass a query prompt value at print time you will need to have a query prompt setup in the BarTender document.  I take it that you've done this and that it has the name of "GRN_NO#".  Or could "GRN_NO#" be the name of a field in the database, which isn't the same thing as a query prompt...

 

See the below video for what a query prompt is and how to set one up:

 

http://www.bartenderbarcodesoftware.com/label-software/training-video-(selecting-records-from-a-database-at-print-time).aspx

0
Avatar
Legacy Poster
コメントアクション Permalink

Hi Ian,

 

Yes this is a prompt I have in my BarTender document it is GRN_NO is the problem then that I have a # in there?

0
Avatar
Ian Cummings
モデレータ
コメントアクション Permalink

Not sure about the #.  However, is that a query prompt specifically, or just a regular user prompt for the general data entry form?  It needs to be a query prompt.

0
Avatar
Legacy Poster
コメントアクション Permalink

Ian,

 

Got it working, thanks for your help. It was the #

サインインしてコメントを残してください。