Do you own a Debenu Quick PDF Library version 7, 8, 9, 10, 11, 12, 13 or iSEDQuickPDF license? Upgrade to Debenu Quick PDF Library 14 today!

Debenu Quick PDF Library - PDF SDK Community Forum Homepage
Forum Home Forum Home > For Users of the Library > I need help - I can help
  New Posts New Posts RSS Feed - Barcode in table
  FAQ FAQ  Forum Search   Register Register  Login Login

Barcode in table

 Post Reply Post Reply
Author
Message
doug_b View Drop Down
Beginner
Beginner


Joined: 01 Feb 10
Status: Offline
Points: 2
Post Options Post Options   Thanks (0) Thanks(0)   Quote doug_b Quote  Post ReplyReply Direct Link To This Post Topic: Barcode in table
    Posted: 01 Feb 10 at 9:08PM

Can a barcode be put into a table cell?

Back to Top
Ingo View Drop Down
Moderator Group
Moderator Group
Avatar

Joined: 29 Oct 05
Status: Offline
Points: 3530
Post Options Post Options   Thanks (0) Thanks(0)   Quote Ingo Quote  Post ReplyReply Direct Link To This Post Posted: 02 Feb 10 at 6:30AM
Hi Doug!

In the online-documentation you can read that the barcode will be drawn on the page.
So why not drawn in a cell of a page? Try it.
If you're speaking from an Excel-cell ... After drawn on the pdf-page you can convert it to an image and then insert it into a cell.

Cheers, Ingo



Edited by Ingo - 02 Feb 10 at 6:30AM
Back to Top
doug_b View Drop Down
Beginner
Beginner


Joined: 01 Feb 10
Status: Offline
Points: 2
Post Options Post Options   Thanks (0) Thanks(0)   Quote doug_b Quote  Post ReplyReply Direct Link To This Post Posted: 02 Feb 10 at 3:12PM
Thanks for suggestions.

I'm trying to layout some shipping labels with bar-codes. I just thought that maybe there was a way to place a bar-code using the table structure. If not, I will just calculate the correct location on the page and use DrawBarcode function. 

Below is a sample of my code. 

           ' Set the page size of the new document
            qp.SetPageSize(PageSize)

            ' Set the Measurement Units to Inchs
            qp.SetMeasurementUnits(2)

            ' Create the table and specify the number of rows and columns
            Dim tableID As Integer
            tableID = qp.CreateTable(10, 3)

            ' Specify color and width of borders   
            qp.SetTableBorderColor(tableID, 0, 1, 1, 1)
            qp.SetTableBorderWidth(tableID, 0, 0.01)

            ' Specify table row height
            For row = 1 To 9 Step 2
                qp.SetTableRowHeight(tableID, row, row, 0.5)
                qp.SetTableRowHeight(tableID, row + 1, row + 1, 1.5)
            Next

            ' Specify table column width
            qp.SetTableColumnWidth(tableID, 1, 3, 3.9)
            qp.SetTableColumnWidth(tableID, 2, 2, 0.2)

            ' Specify Cell Padding
            qp.SetTableCellPadding(tableID, 1, 1, 5, 3, 0, 0.05)

            ' Insert the content for cells
            For col = 1 To 3 Step 2
                For row = 1 To 9 Step 2

'---> I would like to add a barcode 
                    qp.SetTableCellContent(tableID, row, col, "1234567890123")
'---
                    qp.SetTableCellContent(tableID, row + 1, col, _
                    "<p align=""center"">1234567890123</p>")

                Next
            Next

            ' Draw the table onto the document
            Dim s As Double
            s = qp.DrawTableRows(tableID, 0.25, 10.5, 10.5, 1, 0)

            ' Save the document to disk
            qp.SaveToFile(output)

            ' Check to see if the table could be created
            If s = False Then
                MsgBox("Could not create table!")
            End If

            Process.Start(output)


Edited by doug_b - 02 Feb 10 at 3:30PM
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 11.01
Copyright ©2001-2014 Web Wiz Ltd.

Copyright © 2017 Debenu. Debenu Quick PDF Library is a PDF SDK. All rights reserved. AboutContactBlogSupportOnline Store