Quote Originally Posted by thhui View Post
saying it is excluded from safe domain and must obtain my approval of protection to open it.
This is a security feature built into all version of Office after 2000. You can either just ignore it or you can move the MDB file into the same folder as your other database (which should make the message go away on it's own).

. . . Also, upon opening the query, I cannot find the windows interface to have the option to change format. . .
I have a different version of Access than you do. Most likely your problem is caused by Access incorrectly converting my database to your version. As to how to fix it, I couldn't tell you.

. . . I see your form and vba code.
It is using excel vba to format the data after the export.
The same approach like me stated before.
However, with this VBA code, you never have to actually open the Excel file and make the changes yourself. All the changes can be made from Access, allowing you to export more easily.

Quote Originally Posted by dev82 View Post
thanks for the info. but the format in the sheet is wrong. as you already written in your previous message.
I'm not sure I understand. Access doesn't have anything called a "sheet."

If you mean the Excel file, that's what the VBA code is for. All you need to do is change the VBA code to correct the formats for your Query.

My attached file was not supposed to solve the problem for you. It is just an example of how you can make your export work. Most of my code can be copied to your MDB, but it will have to be customized to fit your exact needs.