Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

30 lines
653 B

  1. xmlDoc = new ActiveXObject( "Msxml2.DOMDocument" );
  2. try
  3. {
  4. res = xmlDoc.load( WScript.Arguments(0) );
  5. }
  6. catch(e)
  7. {
  8. res = false;
  9. }
  10. if(res != true)
  11. {
  12. WScript.Echo( "Bad xml "+
  13. WScript.Arguments(0)+
  14. "!!\n");
  15. err = xmlDoc.parseError;
  16. WScript.Echo( "reason : " + err.reason );
  17. WScript.Echo( "line : " + err.line );
  18. WScript.Echo( "linepos: " + err.linepos );
  19. WScript.Echo( "filepos: " + err.filepos + "\n" );
  20. WScript.Echo( err.srcText.substr( err.linepos - 10, 60 ) );
  21. WScript.Echo( "---------^" );
  22. }