自由线程FreeThreadDOMDocument

星期二 天气:晴
 
昨天燕子 自己去五爱了 给我买了一堆袜子 给妈买了一双鞋
给自己买了一件 红色的内衣服 挺好看的
在市场买了一碗麻辣烫 买了二斤香樵 
  一般是用在多线程中的,不过现在好像用不到了这种对象了 除非你还在用asp来写后台程序、或者用
vb、vc之类com组件编程。

function Test(){
    var xmlDom = new ActiveXObject("Msxml2.DOMDocument");
    xmlDom.async = false;
    xmlDom.loadXML(...);

     if(xmlDom.parseError.errorCode != 0){
     var myErr = xmlDom.parseError;
     alert("XML 加载错误: " + myErr.reason);
    }else{
     var xslt = new ActiveXObject("Msxml2.XSLTemplate");
     var xsltDom = new ActiveXObject("Msxml2.FreeThreadedDOMDocument");
     xsltDom.async = false;
     xsltDom.load("??.xslt");
     
     if(xsltDom.parseError.errorCode != 0) {
      var myErr = xsltDom.parseError;
      alert("XSLT 加载错误: " + myErr.reason);
     }else{
      xslt.stylesheet = xsltDom;
      var xslProc = xslt.createProcessor();
      xslProc.input = xmlDom;
      xslProc.transform();
      var openWin = window.open("about:blank","mans","toolbar=no,location=no,menubar=no,scrollbars=yes,left=100,top=100,width=250");
      try{
       openWin.document.writeln(xslProc.output);
      }catch(ex){
      }
     }
    }    
   }

Advertisements
此条目发表在Xml/Xslt分类目录。将固定链接加入收藏夹。

One Response to 自由线程FreeThreadDOMDocument

  1. 赤裸说道:

    生活还是流水一般,看上去挺滋润啊。

发表评论

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  更改 )

Google+ photo

You are commenting using your Google+ account. Log Out /  更改 )

Twitter picture

You are commenting using your Twitter account. Log Out /  更改 )

Facebook photo

You are commenting using your Facebook account. Log Out /  更改 )

w

Connecting to %s