不明白,为什么要使其可见这行代码呢?在服务器端的WORD能可见吗??

解决方案 »

  1.   

    先用phpinfo()看看你的机器是否打开了COM支持.
      

  2.   

    已经输出
    Loaded Word, version 9.0 Version using Com_get(): 9.0 
    说明已经打开COM支持
      

  3.   

    我这里运行正常!应该是你OFFICE的问题。你重新安装OFFICE看看
      

  4.   

    看下面这个将word转换为HTML的实例是否成功,注意文件路径要正确:
    <?
    // starting word
    $word = new COM("word.application") or die("Unable to instanciate Word");// if you want see thw World interface the value must be '1' else '0'
    $word->Visible = 1;//doc file location
    $word->Documents->Open("d:/test.doc");//html file location  '8' mean HTML format
    $word->Documents[1]->SaveAs("d:/test_doc.html",8);//closing word
    $word->Quit();//free the object from the memory
    $word->Release();
    $word = null;
    ?>
      

  5.   

    还是不成功,他说php.exe遇到问题
    我的配置:iis+php+mysql+winxp+office2000请问这问题跟配置有关吗?