Problem with the scaling

PDF-XChange Viewer SDK for Developer's
(ActiveX and Simple DLL Versions)

Moderators: PDF-XChange Support, Daniel - PDF-XChange, Chris - PDF-XChange, Sean - PDF-XChange, Vasyl - PDF-XChange, Ivan - Tracker Software, Stefan - PDF-XChange

adntES
User
Posts: 71
Joined: Fri Mar 25, 2011 5:43 pm

Problem with the scaling

Post by adntES »

I have some wierd problem with the scaling type. If i try to print with the flag PXCVA_Flags.PXCVA_NoUI my page
seem to have a left margin like if the scaling type was on Tile larges. I did try to put the scaling type to none but it just change nothing beside if i write fit to margin. However, if i have the flag '0' and i print with the dialog with none in scaling type it's working great.

I'm kind of confuse
User avatar
Stefan - PDF-XChange
Site Admin
Posts: 19885
Joined: Mon Jan 12, 2009 8:07 am

Re: Problem with the scaling

Post by Stefan - PDF-XChange »

Hello adntES,

Can you please provide a snippet of your code where you are setting the print parameters and starting the printing process, so that we can take a look at it and advise further.

Best,
Stefan
adntES
User
Posts: 71
Joined: Fri Mar 25, 2011 5:43 pm

Re: Problem with the scaling

Post by adntES »

Tracker Supp-Stefan wrote:Hello adntES,

Can you please provide a snippet of your code where you are setting the print parameters and starting the printing process, so that we can take a look at it and advise further.

Best,
Stefan

Here 3 functions that resume the whole thing.

First we do the initiliazed function in the load :

Code: Select all

 Public Sub InitialiserAxViewer()

        Try
            'Les clés du produit
            AxPDFXviewer.SetDevInfo(PDFXKeyCode, PDFXDevCode)

            AxPDFXviewer.OpenDocument(m_FichierAAfficher)

            'set l'id du document
            AxPDFXviewer.GetActiveDocument(ActiveDocId)

            'Set les options affichage
            SettingPDFXUI()
     Catch...
Here the SettingPDFX code to set default option

Code: Select all

Try

 SetAxProperty("International.LocaleID", vDataIn)

            ''SET DISABLE TOOLTIP
            SetAxProperty("Commenting.ShowTooltips", 0)

            ''SET LE ZOOM
            SetAxDocProperty(ActiveDocId, "Pages.Zoom", "Fit Width")

            ''SET HIGHLIGHT FORM FIELD
            SetAxGeneralProperty("", "ExecuteCommand", 36463)

After this, the user have to press print so i can add some setting (depending if it's a dot matrix document or not)

Code: Select all

'DOCUMENT NON MATRICIEL
                    Case Enumeration.Data.EnumDocumentTypeDocument.NonMatriciel

                            ''SET ScaleType pour corriger le bug de la coupure
                            SetAxProperty("Print.ScaleType", "FitToMargins")

                            AxPDFXviewer.SaveDocument(ActiveDocId, FNICommon.EmplacementServeurDoc & _
                                                    m_documentTemplate.GestionDocumentSuffixeEnregistrement & _
                                                    m_soumissionId & GetExtensionString(m_documentTemplate.GestionDocumentTypeExtension), _
                                                    PDFXCviewAxLib.PXCVA_DocumentSaveFlags.PXCVA_DocumentSaveAs, _
                                                    PDFXCviewAxLib.PXCVA_Flags.PXCVA_NoUI)


                            AxPDFXviewer.PrintDocument(ActiveDocId, GetAxFlagUIByVendeurParam(ParametresVendeurCourant))



                            'DOCUMENT MATRICIEL
                        Case Enumeration.Data.EnumDocumentTypeDocument.Matriciel


                            AxPDFXviewer.SaveDocument(ActiveDocId, FNICommon.EmplacementServeurDoc & _
                                                    m_documentTemplate.GestionDocumentSuffixeEnregistrement & _
                                                    m_soumissionId & GetExtensionString(m_documentTemplate.GestionDocumentTypeExtension), _
                                                    PDFXCviewAxLib.PXCVA_DocumentSaveFlags.PXCVA_DocumentSaveAs, _
                                                    PDFXCviewAxLib.PXCVA_Flags.PXCVA_NoUI)


                            ImprimerMatriciel()


                    End Select
For now i put FittoMargins it's seem to "patch the issue" but it's not actually the real size.
The GetAxFlagUIByVendeurParam function just return a flag depending on a user option in our app.
User avatar
Stefan - PDF-XChange
Site Admin
Posts: 19885
Joined: Mon Jan 12, 2009 8:07 am

Re: Problem with the scaling

Post by Stefan - PDF-XChange »

Hi adntES,

Thanks for the samples.

And so to confirm the problem,
you say that if you try to specify
SetAxProperty("Print.ScaleType", 0)
it's not setting the scale correctly for you?

Best,
Stefan
adntES
User
Posts: 71
Joined: Fri Mar 25, 2011 5:43 pm

Re: Problem with the scaling

Post by adntES »

Tracker Supp-Stefan wrote:Hi adntES,

Thanks for the samples.

And so to confirm the problem,
you say that if you try to specify
SetAxProperty("Print.ScaleType", 0)
it's not setting the scale correctly for you?

Best,
Stefan
No it doesn't.. i have to write FittoMarging or put the dialog window with Scale at none to make it fit correctly, otherwise it scale like Tiles.
Without the dialog it does take the default printer but it's seem to not take the setting "none"
User avatar
Stefan - PDF-XChange
Site Admin
Posts: 19885
Joined: Mon Jan 12, 2009 8:07 am

Re: Problem with the scaling

Post by Stefan - PDF-XChange »

Hello adntES,

I asked one of my colleagues to check this, and he says that he is unable to reproduce the problem.
Please ensure that you are using build 195 of our SDKs, and if you are still able to reproduce the issue with build 195, please do attach a whole project with source codes (and make sure the licensing information is NOT visible there) so that we can try to reproduce this once again with your code.

Best,
Stefan