乐筑天下

搜索
欢迎各位开发者和用户入驻本平台 尊重版权,从我做起,拒绝盗版,拒绝倒卖 签到、发布资源、邀请好友注册,可以获得银币 请注意保管好自己的密码,避免账户资金被盗
查看: 13|回复: 0

[编程交流] 弗拉在201年将标题上调

[复制链接]

20

主题

49

帖子

29

银币

初露锋芒

Rank: 3Rank: 3Rank: 3

铜币
100
发表于 2022-7-5 19:51:30 | 显示全部楼层 |阅读模式
在这里,我通过LISP创建表格。这一惯例在2007年运作良好。最近,我们更新了2014年。倾斜抑制和收割台抑制工作正常。
 
在这两种情况下
 
(vla put TitleSuppressed tblstyle:vlax true)
(vla put标题支持tblstyle:vlax false)
 
它显示了收割台和倾斜装置。
 
代码如下
 
  1. (defun c:tab (/ tblstyle adoc)
  2. (setq tHt 2)
  3. (setq name     "BOM_table"
  4.        desc     "BOM table"
  5.        txtstyle "bom_text"
  6.        h1       (* 2 tHt)
  7.        h2       (* 2 tHt)
  8.        h3       tHt
  9. )
  10. (or (vl-load-com))
  11. (setq tblstyle (vla-addobject
  12.                   (vla-item (vla-get-dictionaries (setq adoc (vla-get-activedocument (vlax-get-acad-object))))
  13.                             "Acad_Tablestyle"
  14.                   )
  15.                   name
  16.                   "AcDbTableStyle"
  17.                 )
  18. )
  19. (setq acmCol (vla-getinterfaceobject
  20.                 (vlax-get-acad-object)
  21.                 (strcat "AutoCAD.AcCmColor." (substr (getvar "ACADVER") 1 2))
  22.               )
  23. )
  24. (vla-put-name tblstyle name)
  25. (vla-put-TitleSuppressed tblstyle :vlax-true)
  26. (vla-put-headersuppressed tblstyle :vlax-true)
  27. (vla-put-description tblstyle desc)
  28. (vla-put-flowdirection tblstyle 1)
  29. (vla-put-bitflags tblstyle 1)
  30. (vla-put-horzcellmargin tblstyle 0.25)
  31. (vla-put-vertcellmargin tblstyle 0.25)
  32. ;;;  (vla-settextstyle tblstyle 7 txtstyle)
  33. (vla-settextheight tblstyle 1 h3)
  34. (vla-settextheight tblstyle 4 h2)
  35. (vla-settextheight tblstyle 2 h1)
  36. ;;;  (vla-setrgb acmCol 204 102 0)
  37. (vla-put-colorindex acmCol 1)
  38. (vla-setgridcolor tblstyle 63 7 acmCol)
  39. (vla-setgridvisibility tblstyle 63 7 :vlax-true)
  40. (vla-setgridlineweight tblstyle 18 7 aclnwt009)
  41. (vla-setgridlineweight tblstyle 45 7 aclnwt050)
  42. (vlax-release-object acmCol)
  43. (setvar "CTABLESTYLE" "BOM_table")
  44. (setq acmCol (vla-getinterfaceobject
  45.                 (vlax-get-acad-object)
  46.                 (strcat "AutoCAD.AcCmColor." (substr (getvar "ACADVER") 1 2))
  47.               )
  48. )
  49. (setq mSp (vla-get-ModelSpace (vla-get-ActiveDocument (vlax-get-acad-object))))
  50. (setq vlaTab (vla-AddTable mSp (vlax-3D-point (list 0 0 0)) 4 4 (* 2 tHt) (* 10 tHt)))
  51. ;;;  (vla-DeleteRows vlaTab 0 2)
  52. )
回复

使用道具 举报

发表回复

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

本版积分规则

  • 微信公众平台

  • 扫描访问手机版

  • 点击图片下载手机App

QQ|关于我们|小黑屋|乐筑天下 繁体中文

GMT+8, 2025-3-12 01:31 , Processed in 0.601131 second(s), 65 queries .

© 2020-2025 乐筑天下

联系客服 关注微信 帮助中心 下载APP 返回顶部 返回列表