Help needed from Append Query in Excel VBA

sandrapoh

New member
Local time
Tomorrow, 01:11
Joined
Sep 4, 2013
Messages
8
Hi all,
I need help to investigate my excel vba code.
I have wrote the attached code to run query in the attached access dbase.
But hit the error message "Run Time Error 3085".

I suspect my query definition is not correct. Please teach me what have I done wrong.

Regards
Sandra
 

Attachments

Hi just tried to run your macro and it came up with the error undefined function Nz which is generating your error when creating strTmp2.

I think this is because nz is not recognised in Excel vba which is where you are running the code from.

Here is a link to a workaround

http://www.mrexcel.com/forum/excel-questions/57562-nz-function-excel.html

But don't know if it will work for this situation

Have you considered putting your excel data in an access table and running from there?
 
Dear CL,
Thanks for your help. I got what I need already.

Regards
Sandra
 

Users who are viewing this thread

Back
Top Bottom