Hey Forum,

this is my first thread and I'm sure to find some serious help in here.
Lets jump to my problem.

I created an invoice - form (RE_FRONT) getting and writing its data from/to a table called "Rechnungentbl" which is again stringed to a table called "Kundentbl".Thats because I'm using a combo-box to choose the costumer by dropdown and putting his data (stored in "Kundentbl") into some specified fields of my invoice-form.

Everything works fine so far, I am able to create new invoices, I can switch between the different records the tables are looking fine and so on.


I tried to put up a button to export the data of the actually opened form and current record as an .xml file and I searched many forums to find a direct solution via VBA and a query so that I dont have to open up the build in export xml dialog command but I already accepted, that my knowledge is too low to get that running...

My Problem:

Now I have a button using a click event and a macro with the command:

"RunMenuCommand -- Command -- ExportXML" and I manually choose the "current record" option. Thats ok for me, but it looks like the command only works if my form is in layout view. As soon as I open it up in the form view and try to export it, with the "current record setting" it tells me:

"The current record was not unique. All identical records were exported"

Here is a screenshot: https://dl-web.dropbox.com/get/PROBL...jpg?w=db3f3b51

That is super strange and looks like i dont have a primary key set up, but it is and why does the command work in the layout view and not in the form view...

Thats a lot of information, but I really really hope someone may help. If you got further questions to my case please ask.

Thanks in advance...