乐筑天下

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

[编程交流] Afralisp tutorial #1 driving m

[复制链接]

14

主题

185

帖子

180

银币

初露锋芒

Rank: 3Rank: 3Rank: 3

铜币
73
发表于 2022-7-6 15:22:16 | 显示全部楼层 |阅读模式
Hi all,
 
I've been reading up on .LISP for a bit now and decided to take the
plunge properly and learn it.
 
I have followed the afralisp tutorial to draw a line to the LETTER, and
AutoCAD is saying "; error: too many arguments"
 
What am i doing wrong?
 
  1. (defun c:testline () ;Define Function(setq a (getpoint "\nEnter First Point : ""));Get the First point(setq b (getpoint "\nEnter Second Point : ""));Get the Second Point(command "Line" A b "");Draw the Line(princ);clean running) ;end Defun(princ);clean Loading
回复

使用道具 举报

14

主题

185

帖子

180

银币

初露锋芒

Rank: 3Rank: 3Rank: 3

铜币
73
发表于 2022-7-6 15:28:25 | 显示全部楼层
SORTED
........................................................................
Original Code with error's
 
  1. (defun c:testline () ;Define Function(setq a (getpoint "\nEnter First Point : [color=red]""[/color]));Get the First point(setq b (getpoint "\nEnter Second Point : [color=red]""[/color]));Get the Second Point(command "Line" A b "");Draw the Line(princ);clean running) ;end Defun(princ);clean Loading
 
code with error Fixed.
 
  1. (defun c:testline () ;Define Function(setq a (getpoint "\nEnter First Point : [color=red]"[/color]));Get the First point(setq b (getpoint "\nEnter Second Point : [color=red]"[/color]));Get the Second Point(command "Line" A b "");Draw the Line(princ);clean running) ;end Defun(princ);clean Loading
回复

使用道具 举报

9

主题

167

帖子

163

银币

初来乍到

Rank: 1

铜币
43
发表于 2022-7-6 15:33:16 | 显示全部楼层
  1. (defun c:testline () ;Define Function[color="Red"] (setq a (getpoint "\nEnter First Point : "))[/color];Get the First point[color="Red"] (setq b (getpoint "\nEnter Second Point : "))[/color];Get the Second Point(command "Line" A b "");Draw the Line(princ);clean running) ;end Defun(princ);clean Loading
 
An extra quot marks in red lines in your code
回复

使用道具 举报

14

主题

185

帖子

180

银币

初露锋芒

Rank: 3Rank: 3Rank: 3

铜币
73
发表于 2022-7-6 15:34:31 | 显示全部楼层
cheers paul
回复

使用道具 举报

41

主题

301

帖子

265

银币

后起之秀

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

铜币
209
发表于 2022-7-6 15:38:42 | 显示全部楼层
From this error im assuming you are not using any program to play with them,
i use notpad ++ to make them. its good to see where ive got closed brackets and will run any where.
 
or
 
"_vlide"
 
Which is similar except colours are different, but allows to debug alot easyer, as it tells you where simple mistakes are, and easyer filtering where the bigger mistakes are. and reconises comands and variables
but you need autocad open to make work.
回复

使用道具 举报

14

主题

185

帖子

180

银币

初露锋芒

Rank: 3Rank: 3Rank: 3

铜币
73
发表于 2022-7-6 15:41:10 | 显示全部楼层
I've decided to try learn it when i get free time at work (Which at moment is alot) so as to keep me "looking busy" LOL,
回复

使用道具 举报

41

主题

301

帖子

265

银币

后起之秀

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

铜币
209
发表于 2022-7-6 15:47:43 | 显示全部楼层
yep i kno what you mean.ive being working on many myself, till more work comes in,except my boss thinks its a waste of time.
hes a all tool bars man, who dosnt even do much work lol
回复

使用道具 举报

40

主题

132

帖子

107

银币

后起之秀

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

铜币
227
发表于 2022-7-6 15:50:36 | 显示全部楼层
I never liked toolbars they take up to much screen space as for auto lisp have you looked at the The Visual LISP Developers Bible? pretty good stuff .a little hard to keep up for slow people like. me but it's worth it. everyone on here would agree i'm sure
回复

使用道具 举报

114

主题

1万

帖子

1万

银币

中流砥柱

Rank: 25

铜币
543
发表于 2022-7-6 15:53:30 | 显示全部楼层
I've had a look at that JON before and yes, it is pretty helpful.
回复

使用道具 举报

14

主题

185

帖子

180

银币

初露锋芒

Rank: 3Rank: 3Rank: 3

铜币
73
发表于 2022-7-6 15:58:36 | 显示全部楼层
 
Never even heard of that book m8
回复

使用道具 举报

发表回复

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

本版积分规则

  • 微信公众平台

  • 扫描访问手机版

  • 点击图片下载手机App

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

GMT+8, 2025-3-4 18:19 , Processed in 0.459420 second(s), 83 queries .

© 2020-2025 乐筑天下

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