PDFsharp & MigraDoc Foundation

PDFsharp - A .NET library for processing PDF & MigraDoc Foundation - Creating documents on the fly
It is currently Mon Jun 14, 2021 11:45 pm

All times are UTC

Forum rules

Please read this before posting on this forum: Forum Rules

Post new topic Reply to topic  [ 2 posts ] 
Author Message
 Post subject: Bookmarks
PostPosted: Mon Feb 26, 2007 7:25 pm 

Joined: Mon Feb 26, 2007 7:19 pm
Posts: 1
I am trying to set a bookmark using migra doc lite.
The code below does not set a bookmark and it doesnt add a hyperlink field.
I dont need a hyperlink field, but it has a bookmark property so i thought it might do the trick.
Please review the code below, thanks in advance.


    Private Function SetDocument_Properties(ByVal iInvNum As Integer) As Document
        SetDocument_Properties = New Document
        Dim p As Paragraph

        With SetDocument_Properties
            With .Info
                .Title = "Packing Slips"
                .Subject = "Packing Slips"
                .Author = "SPI"
            End With

            With .LastSection
                p = .AddParagraph
                With p
                    .AddHyperlink(iInvNum.ToString, HyperlinkType.Bookmark)
                End With
            End With
        End With
    End Function

Reply with quote  
 Post subject:
PostPosted: Thu Mar 08, 2007 11:48 pm 
empira Employee
User avatar

Joined: Thu Oct 12, 2006 10:07 pm
Posts: 49
Location: Cologne, Germany
You use hyperlink not correctly.
See in sample HelloMigraDoc how the table of content is created. This illustrates the connection between bookmarks and hyperlinks and how to use them.

Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

All times are UTC

Who is online

Users browsing this forum: Bing [Bot] and 11 guests

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Privacy Policy, Data Protection Declaration, Impressum
Powered by phpBB® Forum Software © phpBB Group