blank report on windows server 2003

The Amyuni PDF Converter is our Printer Driver that enables you to convert any documents to PDF format. If you have any questions about installing and using the Amyuni PDF Converter please post them here.
Post Reply
cedric
Posts: 25
Joined: Thu Jun 16 2005

blank report on windows server 2003

Post by cedric »

Hye ! :?

A convertion of a PowerBuilder datastore which ran on Windows server 2000 doesn't on windows server 2003.

A pdf document is generated but it is blank.

The font used on the document is a standard microsoft font (Arial).

Do somebody know this trouble ?

If not, do somebody see any trouble in my development code.
My PowerBuilder source code follows :

integer nbr_ds

// Initialisation de l'imprimante Amyuni
i_PDFPrinter = DriverInit( i_Nom_Imprimante )
If i_PDFPrinter = 0 Then Return False // Echec

// Résolution
SetResolution( i_PDFPrinter, i_resolution )

// Mise en place des marges
SetHorizontalMargin( i_PDFPrinter, i_marge_horizontale )
SetVerticalMargin( i_PDFPrinter, i_marge_verticale )

SetDefaultConfig( i_PDFPrinter )

// On passe l'imprimante spécifique PDF en imprimante par défaut
If SetDefaultPrinter( i_PDFPrinter ) = 0 Then
// Echec de mise en place de l'imprimante par défaut
DriverEnd( i_PDFPrinter )
Return False
End If

If i_Nom_Imprimante <> left(ds_print[1].Describe('datawindow.printer'),len(i_Nom_Imprimante)) Then
// Il y a eu utilisation de PrinterSetup()
RestoreDefaultPrinter( i_PDFPrinter )
DriverEnd( i_PDFPrinter )
return false
End If

// Mise en place du nom du fichier généré
SetDefaultFileName( i_PDFPrinter, fic_genere )

// Mise en place des options d'impression => pas de prompt et nom initialisé ci-dessus
SetFileNameOptions( i_PDFPrinter, i_NoPrompt + i_UseFileName )

// On active la licence
EnablePrinter( i_PDFPrinter, i_Societe_Licence, i_Code_Activation )

// On imprime le premier datasource en écrasant le fichier existant (si il existe)
ds_print[1].print()

// On imprime les suivants en concatenant
SetFileNameOptions( i_PDFPrinter, i_NoPrompt + i_UseFileName + i_Concatenate )
For nbr_ds = 2 To UpperBound(ds_print)
// On active la licence
EnablePrinter( i_PDFPrinter, i_Societe_Licence, i_Code_Activation )
// print the same list another time to the same PDF file
ds_print[nbr_ds].print()
Next

// On enlève les options
SetFileNameOptions( i_PDFPrinter, 0 )

// On remet l'ancienne imprimante par défaut
RestoreDefaultPrinter( i_PDFPrinter )
DriverEnd( i_PDFPrinter )

Return True


Thanks in advance for help you'll be able to bring me
cedric
Posts: 25
Joined: Thu Jun 16 2005

Blank report on windows server 2003 (SP1)

Post by cedric »

Moreover,

I recently learned that the SP1 Patch was run on my server.

Do you think that this patch is not compatible with amyuni Pdf converter 2.5 ?
Joan
Amyuni Team
Posts: 2799
Joined: Wed Sep 11 2002
Contact:

Post by Joan »

Hello,

Personally, I am not aware of any incompatibility with SP1 for Windows 2003. However I didn't try the printer personally on Windows 2003 with service pack 1 myself.

I checked your code and I didn't see anything wrong about it. You can however try to comment all the code related to setting the printer as default, set the printer as default from the printers panel, restart your application and try to print, will you still gett the same problem?

If ou print, using your same below code, to a physical printer, will you get blank output?
Post Reply