乐筑天下

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

[编程交流] TotalArea, TotalPerim Lisp Err

[复制链接]

4

主题

8

帖子

4

银币

初来乍到

Rank: 1

铜币
20
发表于 2022-7-5 16:44:01 | 显示全部楼层 |阅读模式
I got these LISP file at http://gile.pagesperso-orange.fr/LISP.html
(Always Thanks Mr. GileCAD)
But these Lisp don't work for me.
When I command, I got the following messages.
 
 
 
-----------------------------------------------------------------------------------------------------------
 
Command: perimbox
Param?res courants : PERIMCONV = 1 PERIMPREC = 4
Erreur: too many arguments
 
-----------------------------------------------------------------------------------------------------------
 
Command: totalarea Unknown command "TOTALAREA".  Press F1 for help.
Command: areabox ; error: no function definition: C:TOTALAREA
 
-----------------------------------------------------------------------------------------------------------
 
 
 
What's the problem?
Please Help me!
TotalArea.zip
TotalPerim.zip
回复

使用道具 举报

114

主题

1万

帖子

1万

银币

中流砥柱

Rank: 25

铜币
543
发表于 2022-7-5 17:14:51 | 显示全部楼层
Here are some alternatives: Total Length & Area Programs.
回复

使用道具 举报

55

主题

402

帖子

357

银币

后起之秀

Rank: 20Rank: 20Rank: 20Rank: 20

铜币
274
发表于 2022-7-5 17:32:53 | 显示全部楼层
Another one with combination of both :
 
  1. (DEFUN C:CAREA (/ A B C O P) (IF (SETQ A (SSGET '((0 . "*LINE,CIRCLE,ELLIPSE,HATCH"))))   (PROGN     (SETQ B 0.    P 0.     )     (REPEAT (SETQ I (SSLENGTH A))(SETQ O (VLAX-ENAME->VLA-OBJECT (SSNAME A (SETQ I (1- I)))))(SETQ B (+ B (VLA-GET-AREA O)))(SETQ P (+ P (VLA-GET-LENGTH O)))     )     (SETQ C (STRCAT "\nTotal Area :- \n\n\tIn Meters = "              (RTOS B 2 4)              " Sq.Mtr\n\n\tIn Acre = "              (RTOS (* B 0.000247104393) 2 4)              " Acre\n\nTotal Perimeter :- \n\n\tIn Meters = "              (RTOS P 2 4)              "m"      )     )     (PROMPT C)     (ALERT C)   ) ) (PRINC))
回复

使用道具 举报

15

主题

687

帖子

169

银币

中流砥柱

Rank: 25

铜币
582
发表于 2022-7-5 18:00:54 | 显示全部楼层
These LISP routines do work (and are daily used by many people), but if you're using AutoCAD LT (as shown in your profile) you cannot use any LISP.
 
PS: I also tried to reply you in your double post at TheSwamp.
PPS: to Lee and Satishrajdev, just have a look at theses codes, you'll see these routines does much more than printing values in the command line...
回复

使用道具 举报

发表回复

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

本版积分规则

  • 微信公众平台

  • 扫描访问手机版

  • 点击图片下载手机App

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

GMT+8, 2025-3-13 14:19 , Processed in 0.539411 second(s), 71 queries .

© 2020-2025 乐筑天下

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