exporting results

scott_j_g

New member
Local time
Today, 22:48
Joined
Sep 10, 2012
Messages
3
Hi All

I need a bit of help ... i am trying to create a button in an access 2010 database that will export certain bits of information from within it, i have attached a screenshot, when a something is selected from the drop down list (highlighted in blue) the rest of the form fills in, i would like to export all the red sections, do you know of an easy way of achieving this? i do not have any coding experience

Thanks
 

Attachments

  • Screen Shot 2012-09-10 at 13.13.31.jpg
    Screen Shot 2012-09-10 at 13.13.31.jpg
    90.4 KB · Views: 92
Create a query that shows those fields and that is filtered on your id or code or whatever you have that is unique. If it was id then the criteria on the id field in the query would be something like forms!YourForm!id

Then go into the code for your button, select the code builder and enter something like:

Private Sub NameOfYourButton_Click()
DoCmd.SendObject acSendQuery, "NameOfYourQuery", acFormatPDF
End Sub
 
..or choose another format!~)
 
Thanks Severin that has worked well . . . however ... the results that are being outputted are being multiplied hundreds of times, instead of having half a page with the results, i have full pages (just under 300 of them) ... any thoughts?

Thanks again
 
ignore me, my mistake :P it was outputting the whole database not just the selected items, got it working now thanks a lot for your help :)
 

Users who are viewing this thread

Back
Top Bottom