• 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.

VBA code to printer cell Data to Excel Form

ScionExcel

New Member
newbie to Chandoo & with beginner of MS Excel but totally new to VBA - I've little task to achieve. I'm trying print few fields from each row to forms created on different worksheet but within same excel file.

So I want to select row and click button which will pick fields of that row and print out to form....

if that makes sense?


▬▬▬▬▬▬▬▬▬ Mod edit : thread moved to appropriate forum !
 
ScionExcel
It would be much e-a-s-i-e-r for You
if You would upload a Sample File to get
as close answer as possible with Your case.
The Sample File includes clear idea of You case.
 
ScionExcel
Here You are ...
As You wrote:
So I want to select row and click button which will pick fields of that row and print out to form....
... select any cell and ... follow instructions.
 

Attachments

  • SampleData.xlsb
    22.2 KB · Views: 4
wow - that is awesome!! how did u do that??
Can I also select the field I want to print? or multiple buttons to print different items of the datasheet

for instant
- i want to print who is Remote user by Department
- i want to print who has laptop by Laptop etc etc...
 
Last edited:
ScionExcel
I try to do it as You wrote:
So I want to select row and click button which will pick fields of that row and print out to form....
You 'wanted' to do that one-by-one ... so, isn't that mean one-by-one?
Many other things would be also possible if clear ideas ...
 
You did exactly I posted - thanks for that for sure. I had buttons created on original datasheet which has more data and need to sort if i want Row.A2:F2 goes on form 1, then E2 to J2 goes on form 2 etc etc...
 
ScionExcel ...hmm?
1) Your sent sample file ... looks different than Your original file
That would be challenge for You!
2) As You might notice, Your original logic works ... but there are some challenges .. ex add more rows :) (but You wanted so)
3) There are many possibilities ... but You should send a sample file which is more like Your original ... or You should change a lot?
 
ScionExcel
Save this to OWN folder.
Create to previous folder PDF-folder
There are 'five forms' to use.
Upper row = select if needs PDF
Lower row = select if needs Printer
From 'data' select as below
1st row ... 'user 1 address' ... makes 'Form3' to Printer
1st row ... 'Queens' ... makes 'Form5' to PDF
2nd row ... 'FINANACE' ... makes 'Form2' to PDF
Screen Shot 2018-02-08 at 14.03.03.png
... from every row can select any/all of those Forms to PDF/Printer
 

Attachments

  • SampleData.xlsb
    39.8 KB · Views: 2
Back
Top