From checking the sources, SchedXmlConfig appears to be set as After="InstallFiles" in UtilExtension.wxs.
If your XMLConfig code is to edit a file which is installed by the DuplicateFiles action, XMLConfig will error & your installation will rollback.
This is due to DuplicateFiles having a sequence of 4210 while InstallFiles has a sequence of 4000 (and thus SchedXmlConfig is created with a sequence of 4001) so when SchedXmlConfig runs, your file doesn't exist & causes the error.
Adding
<installexecutesequence>
<custom action="SchedXmlConfig" after="DuplicateFiles"><![CDATA[VersionNT > 400]]></custom>
</installexecutesequence>
as a workaround to my code changes the Sequencing of SchedXmlConfig to 4211 & allows my installer to complete successfully but this could trip other people up quite easily.
This Tracker item was closed automatically by the system. It was
previously set to a Pending status, and the original submitter
did not respond within 21 days (the time period specified by
the administrator of this Tracker).