title: Printing PDF files with VBA
body: <p>I am new to coding with VBA. This is my unfinished code to print documents in a folder containing documents with 3 distinct headers, "DN" "INV" and "PO". I've been searching around for the code/method to print out PDF documents. I tried using the invokeverb "&amp;print" function but it doesn't seem to work. Can someone please teach me how to print it out? Thank you very much :)</p>
  
  <p>P.S. "DN" needs to printed out once, " INV" needs to be printed out 6 times, "PO" needs to be printed out 2 times.</p>
  
  <pre><code>'' To set the path to the current folder
  
  set shApp = CreateObject("shell.application")
  
  currentPath = CreateObject("Scripting.FileSystemObject").GetAbsolutePathName(".") 
  
  set shFolder = shApp.NameSpace( currentPath )
  
  '' To set the items in the current folder as "files"
  
  set files = shFolder.Items()
  
  ''Start of code''
  
  'msgbox("Starting Script")
  
  for each files in files
  
          ' If name contains "DN" '
          if inStr(files, "DN") then
              'print out 1 time'
          end if
          ' if name contains "INV" '
          if inStr(files, "INV") then
              'print out 6 times'
          end if
          ' if name contains "PO" '
          if inStr(files, "PO") then
              'print out 2 times'
          end if
  next
  MsgBox("completed")
  </code></pre>