明经CAD社区

 找回密码
 注册

QQ登录

只需一步,快速开始

搜索
查看: 931|回复: 0

[求助]如何在EXCEL建立图样?

[复制链接]
发表于 2008-8-10 21:40 | 显示全部楼层 |阅读模式

[求助]如何在EXCEL建立图样?
参考 vlxls-functions
http://www.atablex.com/htmls/vlxls-functions.htm

开启 EXCEL
(setq xlapp (vlax-get-or-create-object "excel.application"))
(setq sheet (vlax-get-property xlapp  "ActiveSheet"))
(setq shapes (vlax-get-property sheet "shapes"))

建立LINE,正常
ActiveSheet.Shapes.AddLine(0.0, 0.0, 100.75, 100.75)
(vlax-invoke-method shapes 'AddLine 0.0 0.0 100.75 100.75 )
     
建立Rectangle,错误
ActiveSheet.Shapes.AddShape(msoShapeRectangle, 121.5, 147.75, 99.5, 114.75)
(vlax-invoke-method shapes 'AddShape ShapeRectangle 121.5 147.75 99.5 114.75 )

请问该怎样带入 msoShapeRectangle 这常数值呢?
烦请各位高手可以解答一下
谢谢~

您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2024-5-12 06:32 , Processed in 0.152221 second(s), 25 queries , Gzip On.

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

快速回复 返回顶部 返回列表