注册 登录
明经CAD社区 返回首页

mahuan1279的个人空间 http://bbs.mjtd.com/?7303115 [收藏] [复制] [分享] [RSS]

日志

创建word

已有 605 次阅读2014-10-11 02:25 |个人分类:LISP|系统分类:插件| 创建word

(vl-load-com)
(cond
 ((null msw-wd100Words) (setq a 1))
)
(if (= a 1) (princ "设置失败!") (princ "设置成功!"))
(setq sysdrv (getenv "systemdrive"))
(setq tlbfile (findfile (strcat sysdrv "\\Program Files\\Microsoft Office\\Office12\\msword.olb")))
(vlax-import-type-library
   :tlb-filename tlbfile
   :methods-prefix  "msw-"
   :properties-prefix "msw-"
   :constants-prefix  "msw-"
)
(if mswc-wd100Words (princ "设置成功!") (princ "设置失败!"))
(setq appsession (vlax-create-object "word.Application"))
(vlax-invoke-method (vlax-get-property appsession 'documents) 'Add)
(vla-put-visible appsession  1)

路过

雷人

握手

鲜花

鸡蛋

评论 (0 个评论)

facelist doodle 涂鸦板

您需要登录后才可以评论 登录 | 注册

小黑屋|手机版|CAD论坛|CAD教程|CAD下载|联系我们|关于明经|明经通道 ( 粤ICP备05003914号 )  
©2000-2023 明经通道 版权所有 本站代码,在未取得本站及作者授权的情况下,不得用于商业用途

GMT+8, 2024-4-25 20:09 , Processed in 0.323797 second(s), 16 queries , Gzip On.

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

返回顶部