Hi Everyone,
I'm a real novice, but thanks to the knowledge on these forums I've been able to create a spreadsheet to manage the volunteers at my work. It's very basic but uses a UserForm to input data on the sheet. This data is mainly contact info and what they are involved with, what training they have done and what documentatio we have (have they signed the code of conduct etc). All these are checkboxes...
I've been pretty lucky and have coded to be able "Find A volunteer" which then fills the user form to edit a volunteers details and then save updates etc.
This is working really well...but my next issue is I need to be able to print..something usable. So I devised, what I thought was fool proof, but alas something goes wrong.
I thought I'll see up a word document that looks something like the Userform in terms of design (with IF to show a checkbox for all the activities/training etc). I'll then mail merge with the data from the spreadsheet...this gives me something to print!!
This works really well when I set the mail merge up through word. I can scroll through and see all the volunteers, all the IF fields work well with the mail merge. It looks good and it works...
Now the problem is I'm not the end user of this "system"...the people who will use are very digital unsavvy. So I want to code a "Print" function on the userform that..
1.Saves the update (as I foresee users will forget to click save update before clicking print
2.Opens the word document that i've set up (i've heard this should be a template, but I'm not sure why etc...Need a simple english explanation)
3. Opens the source data for the mail merge
4. Select the correct entry
5.PrintPreview or Straight to print...(Does that print up the print dialog box?)
I've had some other thoughts, such as, selecting the correct entry might be tricky, so how about the print function doing a save update, then saving to a duplicate sheet with headings (so there is only one entry) then using that to mail merge...
I'm having some major problems with the coding...
I was doing what I found on this and other forums with things like
N.B - This obviously isn't from my document, I've come home from work, but this is still bugging me and I don't have remote access...
FYI - When my initial OpenData Source stuff wasnt' working, I recorded a macro in Word to see what it came up with....I then copied this into my Excel VB but it still didn't work...
I can get the document to open, but it doesn't seem connected with the data for mailmerge (can't scroll through the volunteer records)
Please help !! - Am I going down the wrong path? Could copying to a new sheet help with the selecting one record.. Once all that - how do I code to print the result? The more I've thought about it since writing this post the less I think we need print preview, just the print dialog box to come up so we can select the colour printer..
You're help is really appreciated! Thank you!
Meysha
I'm a real novice, but thanks to the knowledge on these forums I've been able to create a spreadsheet to manage the volunteers at my work. It's very basic but uses a UserForm to input data on the sheet. This data is mainly contact info and what they are involved with, what training they have done and what documentatio we have (have they signed the code of conduct etc). All these are checkboxes...
I've been pretty lucky and have coded to be able "Find A volunteer" which then fills the user form to edit a volunteers details and then save updates etc.
This is working really well...but my next issue is I need to be able to print..something usable. So I devised, what I thought was fool proof, but alas something goes wrong.
I thought I'll see up a word document that looks something like the Userform in terms of design (with IF to show a checkbox for all the activities/training etc). I'll then mail merge with the data from the spreadsheet...this gives me something to print!!
This works really well when I set the mail merge up through word. I can scroll through and see all the volunteers, all the IF fields work well with the mail merge. It looks good and it works...
Now the problem is I'm not the end user of this "system"...the people who will use are very digital unsavvy. So I want to code a "Print" function on the userform that..
1.Saves the update (as I foresee users will forget to click save update before clicking print
2.Opens the word document that i've set up (i've heard this should be a template, but I'm not sure why etc...Need a simple english explanation)
3. Opens the source data for the mail merge
4. Select the correct entry
5.PrintPreview or Straight to print...(Does that print up the print dialog box?)
I've had some other thoughts, such as, selecting the correct entry might be tricky, so how about the print function doing a save update, then saving to a duplicate sheet with headings (so there is only one entry) then using that to mail merge...
I'm having some major problems with the coding...
I was doing what I found on this and other forums with things like
Code:
dim wdApp As Application.Word
dim wdDoc As Word.Application
wdApp.Documents.OpenFileName = ("F:\PrintVolunteerInformation.doc")
Mailmerge.OpenDataSource = ("F:\Volunteer Information.xls")
N.B - This obviously isn't from my document, I've come home from work, but this is still bugging me and I don't have remote access...
FYI - When my initial OpenData Source stuff wasnt' working, I recorded a macro in Word to see what it came up with....I then copied this into my Excel VB but it still didn't work...
I can get the document to open, but it doesn't seem connected with the data for mailmerge (can't scroll through the volunteer records)
Please help !! - Am I going down the wrong path? Could copying to a new sheet help with the selecting one record.. Once all that - how do I code to print the result? The more I've thought about it since writing this post the less I think we need print preview, just the print dialog box to come up so we can select the colour printer..
You're help is really appreciated! Thank you!
Meysha