Printing Selected Columns from Multiple Sheets
Closed
Redza Kalam
-
1 Jan 2016 à 00:24
vcoolio Posts 1411 Registration date Thursday 24 July 2014 Status Contributor Last seen 6 September 2024 - 1 Jan 2016 à 03:18
vcoolio Posts 1411 Registration date Thursday 24 July 2014 Status Contributor Last seen 6 September 2024 - 1 Jan 2016 à 03:18
Related:
- How to print selected columns in excel
- Excel mod apk for pc - Download - Spreadsheets
- How to change date format in excel - Guide
- Arrow keys not working in excel - Guide
- Excel column number - Guide
- How to clear formatting in excel - Guide
1 response
vcoolio
Posts
1411
Registration date
Thursday 24 July 2014
Status
Contributor
Last seen
6 September 2024
262
1 Jan 2016 à 03:18
1 Jan 2016 à 03:18
Hello Redza Kalam,
Perhaps the following code may be what you are wanting:-
The code hides the columns that you don't want to print, prints the columns that you do want to print and then unhides all the hidden columns.
I'm not sure of the extent of your dataset, but following is a link to my test work book which will give you an idea of how it works. Click on the Print button to see it work.
https://www.dropbox.com/s/i1vepf20o0g9r3f/RedzaKalam%28Print%20selected%20columns%20in%20multiple%20sheets%29.xlsm?dl=0
I hope that this helps.
Cheerio,
vcoolio.
Perhaps the following code may be what you are wanting:-
Sub PrintIt()
Application.ScreenUpdating = False
Dim ws As Worksheet
For Each ws In Worksheets
ws.Columns("B:K").EntireColumn.Hidden = True
ws.Columns("M:N").EntireColumn.Hidden = True
ws.PrintOut
ws.Columns("B:K").EntireColumn.Hidden = False
ws.Columns("M:N").EntireColumn.Hidden = False
Next ws
Application.ScreenUpdating = True
End Sub
The code hides the columns that you don't want to print, prints the columns that you do want to print and then unhides all the hidden columns.
I'm not sure of the extent of your dataset, but following is a link to my test work book which will give you an idea of how it works. Click on the Print button to see it work.
https://www.dropbox.com/s/i1vepf20o0g9r3f/RedzaKalam%28Print%20selected%20columns%20in%20multiple%20sheets%29.xlsm?dl=0
I hope that this helps.
Cheerio,
vcoolio.