Solved

Help required for PDF creating tool: Capable of producing bookmarks (with evaluation version)

Posted on 2004-03-24
7
298 Views
Last Modified: 2010-04-05
I want to create a PDF file with some text and say five images.
Within the text, I want to add bookmarks for the images (i.e. if the reader clicks on the text, he is led to the image).
Since I am experimenting, I cannot buy the software right-away, so can some body suggest some evaluation software that gives me capability do this (And if possible, exlpain how to use the software!)?
Desperately looking forward to your help,
...Shu
0
Comment
Question by:snehanshu
  • 4
  • 3
7 Comments
 
LVL 11

Expert Comment

by:shaneholmes
ID: 10674447
I didn't know PDF files do that.....

Click on some text and jump to an image


Shane
0
 
LVL 5

Author Comment

by:snehanshu
ID: 10674455
:-(
Really? Can it not be done at all?
...Shu
0
 
LVL 11

Accepted Solution

by:
shaneholmes earned 400 total points
ID: 10674483
I dont know, can it do that?

There are many PDF components available, I have never used one, but I have seent hem

Goto and perform a search at the following Delphi VCL repositories


http://delphi.icm.edu.pl/
www.torry.ru
www.delphi32.com
www.delphipages.com

Example:

http://www.torry.net/quicksearchd.php?String=PDF&Title=Yes

SHane

0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 
LVL 11

Expert Comment

by:shaneholmes
ID: 10674489

This one does bookmarks

http://www.torry.net/quicksearchd.php?String=PDF&Title=Yes

EasyPDF v.1.1  FW 458 Kb 22 Apr 2002
By JanSoft. EasyPDF is a XML to PDF converter supporting: page, text (single line text), section (multi-line text that can auto-flow), font (name, size, leading), stroke (color, width, style), fill (color), shape (rectangle, ellipse), line, function (for repeating blocks and headers and footers), call (for executing a function); included: integrated syntax highlighted editor. Pie-charts, Outlines (bookmarks), Polygons, text-align (left, right, center, centerx), Curve, Axis, Plotgrid, integrated PDF viewer.
Fully functional
Source: None

 
Shane
0
 
LVL 5

Author Comment

by:snehanshu
ID: 10674672
EasyPDF doesn't have code :-(
I am not sure about clicking the text to go to the image, but perhaps what I am looking for is creating/defining outlines in the PDF document.
There is a bookmarks tab in the PDF viewer and I want to put stuff in it.
Can someone please help with delphi code examples?
The images I work with are tiff files, but support for atleast JPEG or bitmap would do for the demo.
Thanks,
...Shu
0
 
LVL 5

Author Comment

by:snehanshu
ID: 10675150
Thanks shaneholmes,
LlPDFLib v.2.2 at torry gave me a very manageable PDF creation utility! Thanks!!
Here's the simple code to generate a new PDF doc using TPDFDocument:

unit Unit1;

interface

uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
  Dialogs, PDF, StdCtrls;

type
  TForm1 = class(TForm)
    Button1: TButton;
    OpenDialog1: TOpenDialog;
    PDFDoc: TPDFDocument;
    procedure Button1Click(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  Form1: TForm1;

implementation

{$R *.dfm}

procedure TForm1.Button1Click(Sender: TObject);
Var
  RootBM, ChildBM: TPDFOutlineNode;
begin
  If OpenDialog1.Execute Then
  Begin

    PDFDoc.FileName := OpenDialog1.FileName;

    PDFDoc.BeginDoc;
//    PDFDoc.NewPage;
    with PDFDoc.CurrentPage do
    begin
      SetLineWidth(1);
      SetRGBColorFill(0.5, 0.5, 0.5);
      SetRGBColorStroke(1, 0, 0);
      BeginText;
      SetTextRenderingMode(2);
      SetActiveFont('Verdana', [], 48);
      TextOut((Width - GetTextWidth('Snehanshu')) / 2, 100, 0, 'Snehanshu');
      SetActiveFont('Arial', [], 48);
      TextOut((Width - GetTextWidth('PDF Demo')) / 2, 240, 0, 'PDF Demo');
      SetRGBColorStroke(0, 0, 1);
      SetActiveFont('Times', [], 100);
      TextOut((Width - GetTextWidth('Hello')) / 2, 280, 0, 'Hello');
      SetRGBColorStroke(0, 0.5, 0.25);
      SetActiveFont('Courier', [], 40);
      SetHorizontalScaling(50);
      TextOut((Width - GetTextWidth('http://www.acs-inc.com')) / 2, 380, 0, 'http://www.acs-inc.com');
      SetHorizontalScaling(100);
{      SetActiveFont('Verdana', [], 12);
      SetRGBColorStroke(0, 0.5, 0.75);
      SetLineWidth(0.5);
      TextOut((Width - GetTextWidth('Copyright '#169' 2001,2002 llionsoft')) / 2, 440, 0, 'Copyright '#169' 2001,2002 llionsoft');}
      EndText;
    end;
    RootBM := PDFDoc.Outlines.Add(nil, 'Root', TPDFGoToPageAction.Create);
    RootBM.Expanded := True;
    ChildBM := PDFDoc.Outlines.AddChild(RootBM, 'Child', TPDFGoToPageAction.Create);
    TPDFGoToPageAction(ChildBM.Action).PageIndex := 0;
    TPDFGoToPageAction(ChildBM.Action).TopOffset := 30;
    ChildBM.Expanded := True;
    PDFDoc.EndDoc;
    ShowMessage('Done!');

  End;
end;

end.

Thanks a lot!!
...Shu
0
 
LVL 5

Author Comment

by:snehanshu
ID: 10675695
BTW,
  This one is also very good: it allows to edit an existing PDF too!
  http://www.gnostice.com/PDFtoolkit.asp
Cheers!
...Shu
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Objective: - This article will help user in how to convert their numeric value become words. How to use 1. You can copy this code in your Unit as function 2. than you can perform your function by type this code The Code   (CODE) The Im…
Introduction Raise your hands if you were as upset with FireMonkey as I was when I discovered that there was no TListview.  I use TListView in almost all of my applications I've written, and I was not going to compromise by resorting to TStringGrid…
Concerto provides fully managed cloud services and the expertise to provide an easy and reliable route to the cloud. Our best-in-class solutions help you address the toughest IT challenges, find new efficiencies and deliver the best application expe…
The Email Laundry PDF encryption service allows companies to send confidential encrypted  emails to anybody. The PDF document can also contain attachments that are embedded in the encrypted PDF. The password is randomly generated by The Email Laundr…

919 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now