Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Pdf Create Object Error 1

Status
Not open for further replies.

FontanaS

Programmer
Joined
May 1, 2001
Messages
357
Location
US
Hello,

I am trying to open a pdf file that i will create and import data from a database.

I am getting a create object error in the first line of code!

Do i need any references in my web project to support adobe acrobat so this will work properly?


The code is -

***** This line is the error ******
Set PDF = Server.CreateObject("Persits.Pdf")

' Create empty param objects to be used across the app
Set Param = PDF.CreateParam
Set TextParam = PDF.CreateParam

' Create document
Set Doc = PDF.CreateDocument


' Create table with one row (header), and 5 columns
Set Table = Doc.CreateTable("width=500; height=20; Rows=1; Cols=5; Border=1; CellSpacing=-1; cellpadding=2 ")
Table.Font = Doc.Fonts("Helvetica")
Set HeaderRow = Table.Rows(1)
Param.Set("alignment=center")
With HeaderRow
.BGColor = &H90F0FE
.Cells(1).AddText "Category", Param
.Cells(2).AddText "Description", Param
.Cells(3).AddText "Billable", Param
.Cells(4).AddText "Date", Param
.Cells(5).AddText "Amount", Param
End With

' Set column widths
With Table.Rows(1)
.Cells(1).Width = 80
.Cells(2).Width = 160
.Cells(3).Width = 50
.Cells(4).Width = 70
.Cells(5).Width = 60
End With


' Populate table with data
Set rs = Server.CreateObject("adodb.recordset")
rs.Open "select * from demo_expense where sessionid='" & session.SessionID & "' order by id", Session("ConnectStr")

The error i get is -

Server object error 'ASP 0177 : 800401f3'

Server.CreateObject Failed

/aar400prp/TestPdf.asp, line 11
line 11 is - (Set PDF = Server.CreateObject("Persits.Pdf"))

Invalid ProgID. For additional information specific to this message please visit the Microsoft Online Support site located at:

THANKS!
 
do you have the persits com installed on server
 
do you know if there is another create object that i can use to interact with adobe acrobat?

the server is maintained by another organization. i can talk to them and have install and register the persits com object. do you know where i get that persits com to have them register and install it?

THANKS!
 
Thanks! I am going to have to look at free alternatives. My company won't pay for anything. I will do some more research on the web. Thanks Again!
 
I found one that i can use for free. the dll is now located on my hard drive in my inetpub folder.

How do i register it? The dll is called - ASPSimpleUpload.dll

Can i test it on my computer by registering it on my computer? that way if it works, i will have the server people install and register it on their computer.

After i register it - what do i place in this create object line ?

Set PDF = Server.CreateObject("Persits.Pdf")
 
you can't call Server.CreateObject("Persits.PDF")

using ASPSimpleUpload.dll

thats a different com

every dll has their method call it, with their own functionality

ASPSimpleUpload.dll, from the name seems like an upload script
 
As far as I know there are no free classic ASP components.
The most affordable asp PDF components are:
easyAspPdf - - good but not reliable
and
~ $70

On the other hand there are 2 free ASP.NET PDF components (like and a couple of free PHP classes.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top