跳至主內容

搜尋

搜尋

Updating Objects Values

評論

11 條評論

  • Avatar
    Legacy Poster

    Have you tried just using the "External File" data source type instead of a complicated VBS to read the file?

     

    [attachment=1517:ExternalFile.JPG]

    0
  • Avatar
    Legacy Poster

    I did as first. but I couldn't manage in that way...

     

    and my script is not so complicated :-)

     

    thanks!

     

    M

    0
  • Avatar
    Legacy Poster

    I actually tried again the suggestion given. I tried that as I said, and  have the same result. I use the out-of -printzone field as an external file now. So, the content is read directly, no VBScript.

     

    Anyhow, if i run the template with text file "A" i have result A. I change the txt file behind the scene to "b",  run again the template, result is still A. I re-run it, result is B now. So same problem.

     

    Also, is there a way to change the name of the file dynamically? File A.txt could be A1.txt once in a while...

     

    thanks,

     

    M

    0
  • Avatar
    Legacy Poster

    And... i might start to think that the test I am doing are not correct... in the sense that when the process is managed through Commander, it may work. Just the test is not.

     

    I'll try and report back...

     

    M

    0
  • Avatar
    Legacy Poster

    It is not working... it is like also using commander the file used as DB is not loaded... 

     

    Beginner's mistake. as i used the rename function in Commander (to .old) obviously the .txt was not retrieved by the template... so now it is ok.

     

    - I use .txt as trigger

    - renamed to .old by Commander

    - picked by the template as .old

     

    M

    0
  • Avatar
    Ian Cummings
    版主

    Make sure you specify the Commander variable "%Trigger File Name%" as the file to use for the print jobs as this will tell BarTender to use the file that Commander just renamed as the input data file.  Do not make an explicit reference to the data file to print with.

    0
  • Avatar
    Legacy Poster

    Ian, thanks... but could you elaborate a bit more? I tried to use the %Trigger... variable in the BT Template instead of the file name, but didn't manage to make it work.

     

    thanks for the help,

     

    Maurizio

    0
  • Avatar
    Ian Cummings
    版主

    You specify it in the BarTender command dialog under the "Text File" tab of your Commander task.  You shouldn't be modifying the BarTender document for this.  I suggest you read through the white paper: http://www.seagullscientific.com/label-software/whitepapers/overview-of-commander-new-201406.pdf

    0
  • Avatar
    Legacy Poster

    Ian, thanks again, but still...

     

    - how am I supposed to indicate the file to be used as database in the BT template? I have 3 options: select file, from Db or from data source. if my file has names like file001.ttx, file002.txt etc., which option should i use?

     

    or maybe should i remove completely the External file object? and how do i read and fill the other objexts o nthe template then?

     

    thanks,

     

    Maurizio

    0
  • Avatar
    Ian Cummings
    版主

    In the BarTender document you simply connect to a template file of the same structure, and then choose the data fields to use for each of your label object data sources.  At print time Commander changes the connection parameters to be connecting to the detected trigger file instead.  Follow the white paper example and you'll be golden.

    0
  • Avatar
    Legacy Poster

    Ian,

     

    i see that. But I cannot use a database as I need to have a Header/Detail file. So i still struggle to understand what kind of object should I use to store the data.

     

    I managed to have the External file be loaded and used, but still I rely on a fix name in the VBScript. I'd need to have that filename variable.

     

    sorry if i struggle to understand...

     

    thanks,

     

    Maurizio

    0

登入寫評論。