Maybe could be this the problem? Is reusing the page tag again, there's no way to differenciate which windows are pages and which are dialogs. Maybe the xml formatting for the ams projects is wrong (Im not xml coder, so Im not really sure what the problem is...)
As for whether exporting or editing project's scripts, I am used to save (with lua files) a plain text's code with not formatting as a backup if a hdd disk failure ocurrs (which it was my case) I lost several projects with a lot of number of lines on it, so they could be printed to reuse, restore or study codes I did in the past and scan them with software to recognizes their fonts to save in txt files. Another way was backing the projects up but that did fell reliable for me cos it could be lost if failure occurs. I think it's a way of thinking (for me), for me I see easy working in this way. Another reason is to export all project in a files or files to print in A3 sheets to read and work the code because I have view problems with my tired eyes so I prefer not to spend many hours at screen only when its required.
I see you spent many hours making a sample to get a idea of the issues you detected, I did not pretend you make to work your code, anyway I see that huge effort with the suf script explorer so I decided to make some donation to you (early two days past this weekend) for your hard work. Maybe in some near future for AMS you could achieve this goal (with dialogs).

Leave a comment: