Find and Print PDF Files

MonH

New Member
Joined
Mar 7, 2011
Messages
2
I would like to create a VBA that looks for and once found will prompt for a number of copies to print and will print the file.
I would like to see a form that has buttons on it with the different files that I need. i.e Part Numbers. Once a part number is selected it will go off and find the PDF file to match this which has the same file name as the part number. So you may click on P/No 638836, and it will go off and look for C:\Public\638836.pdf and print the number of copies you requested when you selected the P/No.

I hope this is not too much ramble!
 

Excel Facts

Test for Multiple Conditions in IF?
Use AND(test, test, test, test) or OR(test, test, test, ...) as the logical_test argument of IF.
Hi and welcome to the forum,

I think what you will need to establish is creating a user form with a text box to enter your P/No number or a drop down which will list all the P/No numbers then a text box so you can type in the amount of printed copies you need, then a command button to search for the file.

What is your VBA knowledge like? What version of MS Office are you using?

To start with you need to create the form, so a good idea is watch a tutorial for creating Excel UserForms perhaps one place to get you started is using YouTube.

Some websites like the following will get you going.

http://www.contextures.com/xluserform01.html
http://www.youtube.com/watch?v=wqQFFPomMAU
 
Upvote 0
Thankyou for that information Trevor, very useful, and something I never realised existed in Excel! I am running the 2007 version and have somewhat limited knowledge in VBA. I have worked with it previously but mainly in Access, I assume it cannot be too different?!
Anyhow I have managed to create the userform as suggested, and now would like some type of assistance writing code that says look for C:\&"cboPart"&.pdf and then print "txtqty" amount of copies?

Any ideas.

Thankyou in advance
 
Upvote 0

Forum statistics

Threads
1,222,118
Messages
6,164,066
Members
451,870
Latest member
Nikhil excel

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top