Single PDF with Multiple invoices data

A Pdf contains Multiple invoice numbers i am trying to read all the invoice numbers but when one invoice number is not matched it will be moved into other folder but the pdf should move to the other folder after reading all the invoice numbers even one of the invoice number is not matching how?
Any one help me on this

@Udayreddy - how are you reading the invoice numbers?

i am extracting invoice number by using regex