80mm Thermal Printer (PSO-80) affects me PDF range

kapela2017

New Member
Joined
Oct 16, 2022
Messages
34
Office Version
  1. 365
Platform
  1. Windows
In vba the following macro If it is not installed it works perfectly:
VBA Code:
With wsDestino.PageSetup
  
        .PrintArea = pdf_range.Address
        .Orientation = xlPortrait
        .Zoom = False
        .LeftMargin = Application.InchesToPoints(0.2)
        .RightMargin = Application.InchesToPoints(0.2)
        .TopMargin = Application.InchesToPoints(0)
        .BottomMargin = Application.InchesToPoints(0)
        .HeaderMargin = Application.InchesToPoints(0)
        .FooterMargin = Application.InchesToPoints(0)
        .FitToPagesTall = False
        .FitToPagesWide = 1
        .CenterHorizontally = True
        .RightFooter = "Page &P of &N pages."
    End With
    
    fechaShape.TextFrame.Characters.Text = fechaHoy


   pdf_range.ExportAsFixedFormat Type:=xlTypePDF, Filename:=ar, Quality:=xlQualityStandard, IncludeDocProperties:=True, OpenAfterPublish:=False


    'MsgBox "La Lista fue Creada Exitosamente", vbInformation, "Exito"
    For Each Tbl In wsDestino.ListObjects
        If Tbl.Name = "Compras1" And Tbl.ListRows.Count > 0 Then
            Tbl.DataBodyRange.Delete
        Else
            Tbl.Delete
        
        End If
        
    Next Tbl

1727738285307.png



1727739016792.png



To see the complete table I have to uninstall the printer, it is possible to unlink the range Pdf from the Printer paper size ????
I appreciate your suggestions
VBA Code:
 

Excel Facts

Spell Check in Excel
Press F7 to start spell check in Excel. Be careful, by default, Excel does not check Capitalized Werds (whoops)

Forum statistics

Threads
1,223,761
Messages
6,174,344
Members
452,556
Latest member
Chrisolowolafe

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top