print using other printer than the default printer

mark692

Active Member
Joined
Feb 27, 2015
Messages
321
Office Version
  1. 2016
Platform
  1. Windows
hi guys i have this macro code

VBA Code:
Range("Table24").Select
Selection.Copy
ActiveSheet.Cells(Rows.Count, 50).End(xlUp).Select
Do While ActiveCell = Empty
    ActiveCell.Offset(-1, 0).Select
    Loop
    ActiveCell.Offset(1, 0).Select
    Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
        :=False, Transpose:=False

       
''put printer macro here

on the last part of my macro i want to put a code that will print my table, my problem is when i put this code

VBA Code:
ActiveSheet.PrintOut

the worksheet is printed using my default printer. i want a code that will print my worksheet using my other printer. thanks
 

Excel Facts

Bring active cell back into view
Start at A1 and select to A9999 while writing a formula, you can't see A1 anymore. Press Ctrl+Backspace to bring active cell into view.
I know you said that the printer problem is solved but just out of curiosity, what does this do?
Code:
ActiveSheet.Cells(Rows.Count, 50).End(xlUp).Select
Do While ActiveCell = Empty
    ActiveCell.Offset(-1, 0).Select
    Loop
    ActiveCell.Offset(1, 0).Select
 
Upvote 0
I know you said that the printer problem is solved but just out of curiosity, what does this do?
Code:
ActiveSheet.Cells(Rows.Count, 50).End(xlUp).Select
Do While ActiveCell = Empty
    ActiveCell.Offset(-1, 0).Select
    Loop
    ActiveCell.Offset(1, 0).Select

that codes are part of my project on my worksheet :D it paste copied data to another table then print the table after pasting
 
Upvote 0

Forum statistics

Threads
1,214,622
Messages
6,120,572
Members
448,972
Latest member
Shantanu2024

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