找回密码
 立即注册

QQ登录

只需一步,快速开始

扫一扫,访问微社区

查看: 1635|回复: 4

[每日一码] Script Writer

[复制链接]

已领礼包: 1999个

财富等级: 堆金积玉

发表于 2013-6-29 14:09:02 | 显示全部楼层 |阅读模式

马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。

您需要 登录 才可以下载或查看,没有账号?立即注册

×
Script WriterProgram Description

The aim of this program is to reduce the construction of an AutoCAD Script to a single line.

The program assumes the user is conversant in writing scripts for AutoCAD, if not, refer to my tutorial: An Introduction to Script Writing.

This program is designed to greatly reduce the time involved in writing scripts as an alternative to the usual scripting programs available.

Upon starting the program, the user is presented with a dialog interface. Near the top, the user may enter a Script Line - this is the list of commands that will be performed on each drawing in the selected directory (and subdirectories).

The user only needs to write the first line of the script, which will be performed on every drawing in the selected directory; this is achieved through the use of a special token string to represent the drawing filename in the line of script operations.

请点击此处下载

查看状态:需购买或无权限

您的用户组是:游客

文件名称:Script Writer V1-2.lsp 
下载次数:17  文件大小:29.79 KB 
下载权限: 不限 以上  [免费赚D豆]



Example

Consider the example from my script writing tutorial:
  1. _.open "C:\My Folder\Drawing1.dwg" _.circle 0,0,0 5 _.save  _Y _.close
  2. _.open "C:\My Folder\Drawing2.dwg" _.circle 0,0,0 5 _.save  _Y _.close
  3. _.open "C:\My Folder\Drawing3.dwg" _.circle 0,0,0 5 _.save  _Y _.close


To avoid having to construct the whole script, we can convert the first line for use with the Script Writer program, as follows:
  1. _.open *file* _.circle 0,0,0 5 _.save  _Y _.close


The program will then replace this token with the filename of each drawing in the selected directory (and subdirectories), and subsequently run the constructed script.

Additional Controls

The programs provides additional buttons to save even more time in writing the script line operations: the user may quickly insert the *file* token or clear the existing line by pressing the Filename and Clear buttons respectively.

Scripts may also be saved for later use, or existing scripts may be loaded into the program using the Load / Save buttons.

                                            Preview
WScript.png



评分

参与人数 1D豆 +5 收起 理由
ScmTools + 5 很给力!经验;技术要点;资料分享奖!

查看全部评分

论坛插件加载方法
发帖求助前要善用【论坛搜索】功能,那里可能会有你要找的答案;
如果你在论坛求助问题,并且已经从坛友或者管理的回复中解决了问题,请把帖子标题加上【已解决】;
如何回报帮助你解决问题的坛友,一个好办法就是给对方加【D豆】,加分不会扣除自己的积分,做一个热心并受欢迎的人!

已领礼包: 40个

财富等级: 招财进宝

发表于 2013-6-29 14:30:44 | 显示全部楼层
Dear,SIR
   Thanks
论坛插件加载方法
发帖求助前要善用【论坛搜索】功能,那里可能会有你要找的答案;
如果你在论坛求助问题,并且已经从坛友或者管理的回复中解决了问题,请把帖子标题加上【已解决】;
如何回报帮助你解决问题的坛友,一个好办法就是给对方加【D豆】,加分不会扣除自己的积分,做一个热心并受欢迎的人!
回复 支持 反对

使用道具 举报

已领礼包: 2688个

财富等级: 家财万贯

发表于 2013-6-29 17:59:54 | 显示全部楼层
Nice! Thanks for sharing!
论坛插件加载方法
发帖求助前要善用【论坛搜索】功能,那里可能会有你要找的答案;
如果你在论坛求助问题,并且已经从坛友或者管理的回复中解决了问题,请把帖子标题加上【已解决】;
如何回报帮助你解决问题的坛友,一个好办法就是给对方加【D豆】,加分不会扣除自己的积分,做一个热心并受欢迎的人!
回复 支持 反对

使用道具 举报

发表于 2013-6-29 20:39:55 | 显示全部楼层
哪位高手花时间汉化一下,谢谢楼主分享
论坛插件加载方法
发帖求助前要善用【论坛搜索】功能,那里可能会有你要找的答案;
如果你在论坛求助问题,并且已经从坛友或者管理的回复中解决了问题,请把帖子标题加上【已解决】;
如何回报帮助你解决问题的坛友,一个好办法就是给对方加【D豆】,加分不会扣除自己的积分,做一个热心并受欢迎的人!
回复 支持 反对

使用道具 举报

发表于 2013-7-5 07:11:18 | 显示全部楼层
楼上说的是,呵呵!
论坛插件加载方法
发帖求助前要善用【论坛搜索】功能,那里可能会有你要找的答案;
如果你在论坛求助问题,并且已经从坛友或者管理的回复中解决了问题,请把帖子标题加上【已解决】;
如何回报帮助你解决问题的坛友,一个好办法就是给对方加【D豆】,加分不会扣除自己的积分,做一个热心并受欢迎的人!
回复 支持 反对

使用道具 举报

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

本版积分规则

QQ|申请友链|Archiver|手机版|小黑屋|辽公网安备|晓东CAD家园 ( 辽ICP备15016793号 )

GMT+8, 2024-4-20 00:25 , Processed in 0.222871 second(s), 48 queries , Gzip On.

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

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