You didn't set strSQLQuery to anything, so it is null and the error occurs.