Hi!

I have an Excel-based form for users to fill and submit via commandbutton. I used VBA SaveCopyAs Workbook method, users had Write access to the designated network folder and things worked fine. However I wanted to make the exported data more lightweight and just export the necessary data in XML, not save copy of the entire workbook. I mapped the XML and used ActiveWorkbook.XmlMaps("Data_Map").Export method.

But now users start to get an error. Also, the target folder will have *.tmp file + .xml file (0 kb) saved there. While SaveCopyAs works fine with Write rights, it does look like Excel XML export writes a TEMP-file to the target folder first and then converts the TEMP-file into XML-file... when the file has already been saved. Unlike with SaveCopyAs function, this would require, not just Write rights, but also Modify rights to the target folder - which I don't want users to have. Although, sure enough, things work fine with upgraded access rights.

Any idea if there's a way to avoid this temp-file saving + conversion, so that it could still be run with just Write access?
I assume another option would be to have one designated folder with Modify rights + then use FileSystemObject Move method within the same VBA script after the XMLExport is completed. I assume Move command would work with Write rights to the target folder too.

However before making things more complicated - is there a way to avoid this TEMP-file saving and conversion to XML in target folder? Not having my hopes up, but wanted to make sure.

Thanks a lot!