Beware of inserting data like this:

VB Code:
  1. VALUES ('" & strFilepath & "','" & strFileName & "'

If the strFilePath var contains a single quote in it, it will fail. Use REPLACE on EVERY var to change all single quotes to two single quotes. It will go in the database as only one.

Like this...

VB Code:
  1. VALUES ('" & Replace(strFilepath,"'","''") & "','" & Replace(strFileName,"'","''") & "'