maheshwari_a
12 years agoNew Contributor
XML Checkpoint
Before the create the xml Checkpoint , i have to perform some actions in the system for the xml file to be generated.once the file is created i will start creating the xml checkpoint where in the sour...
- 12 years ago
Hi Maheshwari,
There are a few approaches that you can use:
1. If there is only one XML file in the folder where you store your XML files, you can use the aqFileSystem.FindFiles method to get the file and pass it to the Check method for comparison:
var foundFiles, aFile;
foundFiles = aqFileSystem.FindFiles("C:\\Work\\", "4444_*.xml");
if (foundFiles == null)
return;
aFile = foundFiles(0);
XML.XMLCheckpoint1.Check(aFile);
2. If there are many XML files in the folder, you can get the last modified file. For this, you need to check the result of the GetLastWriteTime method.