• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Command to print selected columns for multiple users

John House

New Member
Hi all,

Just starting to experiment with coding in Excel - so perhaps I am trying to run before I can walk!

I have created an Excel sheet that is to be used as a register for students. The sheet is going to be accessed and updated by multiple users who all teach the students at different times.

The sheet design itself is fairly simple - student names going down in Column A and then dates of lessons in the other columns going accross which will be marked as Present, Absent, Late etc.

What I want to do is create a simple way a user can select which columns to print on one sheet in a simple and effective way so this can then be used as a paper register in their session.

For example user A needs to print column A (student names) and column E (which is the column with the date of their lesson in). They will then have a print out of students and a space to mark who was present.

I cannot work out a user friendly way of doing this - anyone got any ideas?

Thanks!
 
John House
You could test this sample ...
1) You select needed columns (non Yellow will print) with cells B10:G10
2) Select cell A10 [ PRINT] to print sheet
( PS. to modify those 'headers' You need to do some coding :)
Questions?
 

Attachments

  • JohnHouse.xlsb
    42.6 KB · Views: 8
Attach a workbook with fictitious names in so we know how your sheet is organised (Not a picture of one).
 
Workbook is attached - this is a rough sketch put together just to play with ideas, so excuse the lack of design at this stage.

Basically I want a user to be able to select Column A (student names) along with another column(s) of their choice to print out.
 

Attachments

  • sample register.xlsx
    44.3 KB · Views: 5
John House
You could test this sample ...
1) You select needed columns (non Yellow will print) with cells B10:G10
2) Select cell A10 [ PRINT] to print sheet
( PS. to modify those 'headers' You need to do some coding :)
Questions?


This is is the sort of thing I was trying to achieve, I guess my only questions would be - is it possible to change it so you click so select to print rather than select to not print as generally users will only want to print 2 columns.
Also is it easy to adapt so instead of printing it simple exports the data to a new workbook or sheet?
 
John House
To select needed or no needed ...
... both ways are possible - it needs one more selector.

Do Your sample has final layout?
eg A-column has Group-information (could select by group),
B-column has Name-information.

... and what else there would be?

To select target (printer, PDF, sheet, workbook ...) are also possible.
> You asked only to printer.

Ps. Terms 'easy' or 'simple' are interesting, whatever those would mean!
 
Attached is a solution… of sorts.
There are some filters at the top of the sheet (they're actually called Slicers) and they're quite good because you can click in them just using the mouse, or you can select several items holding down the Ctrl key to select/unselect multiple non-contiguous items, or with the shift key to select contiguous items. The remaining available choices in the other slicers is shown by different shading (and they're at the top).
If nothing shows, you can clear all the filters in each slicer:
upload_2018-9-12_17-16-13.png

I've set it up manually, but this aspect could be automated later (trouble is I'm not around for a week a more starting tomorrow).

There's a pivot table based on transposed data on a hidden sheet.
There's a macro in that sheet's code-module (a one-liner) and some 10 lines of code in a standard code-module.

If it's a route you'd like to follow we can develop it to make it more general and tailor it to you, however I'm not going to be able to do a great deal in the coming week.
 

Attachments

  • Chandoo39720sample register.xlsm
    29.5 KB · Views: 4
Last edited:
Back
Top