ASP动态生成PowerPoint文档!

January 14th, 2006

« 编译适合ThinkPad本本的Linux Kernel!   |    Google Sitemaps之我们检测到您的 404(找不到文件)错误页面在响应标头中返回状态代码 200 (OK)! »

这些天,应特殊的要求,要用ASP操作M$ Office中的PowerPoint组件,动态生成PPT文件.
(幸好ASP是M$自己的东西,使用COM组件很简单,基本上和VB/C#使用COM组件的方式一样的).

在ASP中,调用PowerPoint组件的方式很简单了:

ASP:
  1. var objApp = Server.CreateObject("PowerPoint.Application");

在这之前,我用Google搜索了一下ASP内置对象Server的用法,搜索的结果有很大部分是一样的,网页的名字叫这个: ASP之对象总结.
打开这个文章,发现了一个奇怪的地方:

ASP:
  1. Server.CreateXObject("Word.Application")   //Server
  2.  

这个CreateXObject是什么东西啊?Server对象有这个方法啊?

直接放在ASP文件里面试了一下,提示出错,Server对象无此方法/属性.
直接以这个CreateXObject为关键字在Google上搜索了一下,发现这个函数是这样的:

JAVA:
  1.  
  2. org.apache.xalan.xslt
  3. Class XSLTEngineImpl
  4. java.lang.Object
  5.   |
  6.   +-org.apache.xalan.xslt.XSLTEngineImpl
  7.  
  8. public class XSLTEngineImpl
  9. extends java.lang.Object
  10. implements XPathEnvSupport, XSLTProcessor
  11.  
  12.  XObject createXObject(java.lang.Object o)
  13.           **For advanced use only** Convenience function to create an XObject.
  14.  

晕..这个是Java的,和ASP八竿子打不着啊....

再看,基本上,出现CreateXObject的和ASP相关的地方,只有中文网站,而且网页名同样为 ASP之对象总结 .

唉............
受不了啊,太没有职业素质了....

Bookmark on del.icio.us

, , , ,

Add a New Comment

Comment Guidelines: Basic XHTML is allowed (a href, strong, em, code). Line breaks and paragraphs are automatically generated. Off-topic or inappropriate comments will be edited or deleted. Email addresses will never be published. Thanks.

Subscribe without commenting

Related Posts.

  • No Related Posts
  • Widgets

    technorati
    Technorati
    Blogs that link here
    Creative Commons License
    This work is licensed under a Creative Commons Attribution-ShareAlike 2.5 License.