跳至主內容

搜尋

搜尋

Bartender Prints When I Select "test Print" But Not When I Select Print

評論

6 條評論

  • Avatar
    Domingo Rodriguez
    版主
    Hello, a few questions:

    1. What exact Edition, Version and Build of BarTender is in use?

    2. Are you using a Seagull driver for your Zebra printer? If yes, what version?

    3. How is the Zebra printer connected to the PC where your ActiveX application runs, is it locally connected (LPT, COM, USB), directly connected to the internal IP address of the printer... ?

    4. From the code, I'm not sure if this is C#.Net or VB.NET. Please clarify.

    5. Using COM Automation is obsolete. Why are you not making use of our .NET SDKs instead?

    6. Have you tried using the Print() method instead of PrintOut() ?
    0
  • Avatar
    Legacy Poster

    Hello, a few questions:

    1. What exact Edition, Version and Build of BarTender is in use?

    2. Are you using a Seagull driver for your Zebra printer? If yes, what version?

    3. How is the Zebra printer connected to the PC where your ActiveX application runs, is it locally connected (LPT, COM, USB), directly connected to the internal IP address of the printer... ?

    4. From the code, I'm not sure if this is C#.Net or VB.NET. Please clarify.

    5. Using COM Automation is obsolete. Why are you not making use of our .NET SDKs instead?

    6. Have you tried using the Print() method instead of PrintOut() ?

     

    Thank you for responding.

     

     

    1) Edition: Enterprise Automation (3 Printers)

        Version: 10.1 SR2

        Build: 2945

      

    2) Yes

     

    Printer:    Zebra Z4M (203 dpi)
    Port:    192.168.1.188

    Product:    Zebra ZPL-II Driver
    Version:    7.3.4

    Build Target:    x64
    Build Date:    11/13/2013, 12:23 PM
     

    3) IP

     

    4) None of the above, the software has an integraded development environment, which is eventually translated into C#->CLR.

     

    5) Your .NET SDK is built on an outdated Dotnet framework of Ver 2, my app doesnt like that we dont have access to the actual assemby code so I cant rebuild them without creating a wrapper, I'd prefer not to do that. Also if I used that I would much prefer to run it server-side but after several test (.net wrappers) it doesnt appear that it wants to run under a service

     

    6) For some reason it gets upset with the messages parameter (object, yes its the right one messges vs message that I'm passing) that is passed to it, I was hoping to see if it returned some sort of error.  Is there some other place I can check what is getting returned(log or something that bartender keeps, I dont see anything interesting in the windows app log)?

     

     

    The confusing part is why on earth does it work with "test print" and not "print"? What is the difference between the 2?  Is there anything else I should be specifiying in the format or the app object?

    0
  • Avatar
    Domingo Rodriguez
    版主

    The "Test Print" button will print the first label of your print job. If you send a print job with one label to be printed, the "Print" button will give you the exact same printer code than if you would use "Test Print"...

     

    Yes, you can enable logging in BarTender via the "Administer > Log Setup > Text File Log" dialog.

     

    Sorry, but I'm not sure if you've tested yet or not to use Print() rather than PrintOut(). Please confirm and let me know what problems you're having when using Print()

    0
  • Avatar
    Legacy Poster

    The "Test Print" button will print the first label of your print job. If you send a print job with one label to be printed, the "Print" button will give you the exact same printer code than if you would use "Test Print"...

     

    Yes, you can enable logging in BarTender via the "Administer > Log Setup > Text File Log" dialog.

     

    Sorry, but I'm not sure if you've tested yet or not to use Print() rather than PrintOut(). Please confirm and let me know what problems you're having when using Print()

     

    When I try .print I get a type mismatch which I assume has something to do with the messages object, not sure why.

     

     

    bt_Format.Print('TESTJOB',FALSE,-1,bt_Messages)

     

    and

     

    bt_Messages = 'BarTender 10.1'.Messages

     

    I realize this is an overloaded method however when I try to use the simplest one with only a printjob name even though the complier has no problem with it at runtime I get a parameter is not optional error.

     

     

     

     

    OK with logging on now I'm getting somewhere:

     

     

     

    2014-03-27    11:50:48    1200    Information    Database    OK    SQL Statement:  SELECT "timestamp", "Entry No_", "UserID", "ShipName", "OrderNum", "ShipMethod", "ShipAddr", "ShipPhone", "ShipCity", "ShipState", "ShipPost", "NoLables", "ItemNo", "Description", "BarCode", "ShipCitystateZip", "NoOf", "FormatType" FROM "dbo"."BarTender Label"

     

    2014-03-27    11:51:19    3239    Error    Database    OK    OLE DB has encountered error 0x80040E31:    Unknown error.    OLE DB error message:    IDispatch error #3121


     

     

    It definitely looks like its having trouble with retrieving the records.  The label should read records out of a SQL database table in order to get the information to print on the label.   I thought that information for the database connection should be stored in the label definition and it appears to work fine when I was designing the label(the .btw file).  How does it know at runtime how to connect to SQL? Is there some way to specify the connection info when I call the COM object(Ie perhaps setting up a DSN on the machine and passing it somehow)?

    0
  • Avatar
    Legacy Poster

    This is defintely a connection issue. 

     

     

    --edit--

     

    Got it, SQL permissions issue. thanks for the help

    0
  • Avatar
    Domingo Rodriguez
    版主

    Good to know that problem is solved. Thanks for the update

    0

登入寫評論。