If you run the following program using v2.21.10 on Windows:-
IMPORT xml
IMPORT os
MAIN
DEFINE any_errors SMALLINT
DEFINE doc xml.DomDocument
LET doc = xml.DomDocument.create()
CALL doc.load("h:/test.xml")
CALL os.Path.delete("h:/test.xml") RETURNING any_errors
DISPLAY "File Exists (Try1)? ",os.Path.exists("h:/test.xml")
LET doc = NULL
CALL os.Path.delete("h:/test.xml") RETURNING any_errors
DISPLAY "File Exists (Try2)? ",os.Path.exists("h:/test.xml")
END MAIN
You get the following output:-
File Exists (Try1)? 1
File Exists (Try2)? 0
My question is should Load() still be locking the file after it has completed? For me it should not but I just thought I'd mention it...
Regards,
David