Syncfusion PDF

Is there anyway  I can populate a syncfusion pdf from an sql database with assign each value line by line?  I would like to bind the pdf to the database similar to binding a datasource to a gridview.  Right now, I use the following method.

Private Sub FillIncidentTable(ByVal form As PdfLoadedForm)
        Dim connFF = New SqlConnection(Application("connFF"))
        Dim FillCommand As New SqlCommand("spFFPrintIncident", connFF)
        FillCommand.CommandType = CommandType.StoredProcedure

        Dim Filladapt As New SqlDataAdapter(FillCommand)
        Dim DS As New DataSet()

        strcasenumber = listBox.SelectedValue

        Dim casenumber As New SqlParameter("@casenumber", SqlDbType.VarChar)
        casenumber.Value = strcasenumber


        Dim dt As DataTable
        dt = DS.Tables(0)
        Dim data As DataRow = dt.Rows(0)

        Dim status As String = data("vchcasestatus").ToString()
        If status = "Pending" Then
            TryCast(form.Fields("GroupStatus"), PdfLoadedRadioButtonListField).Items(0).Checked = True
        ElseIf status = "Inactive" Then
            TryCast(form.Fields("GroupStatus"), PdfLoadedRadioButtonListField).Items(1).Checked = True
        ElseIf status = "Closed" Then
            TryCast(form.Fields("GroupStatus"), PdfLoadedRadioButtonListField).Items(2).Checked = True
        End If
        TryCast(form.Fields("vchname"), PdfLoadedTextBoxField).Text = data("vchownerLast") + ", " + data("vchownerfirst") + " " + data("vchownermi")

    End Sub

Open in new window

Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Randy Knight, MCMPrincipal ConsultantCommented:
I'm not familiar with Syncfusion but I would think you'd need to iterate your datatable in a For .. Each loop and write the data out to the pdf.  I've never seen a PDF component that allows binding like you are trying to do.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
.NET Programming

From novice to tech pro — start learning today.