Text entry advice needed help please

This a question related to text change, and entry. I have a schematic with
several hundred
device addresses. How can I enter these in a fast efficient manner. I realize I
can
go from one point to another, and either do a text change, or an attribute
change. There has to
be a more elegant way to do this. Speed is essential. Sometimes the numbers are
contigous, but sometiimes not. What is a good technique? Any help would be much
appreciated.
TIA,
Dennis
Reply to
Dennis
Loading thread data ...
Dennis wrote in news: snipped-for-privacy@corp.supernews.com:
it sounds similar to numbering rooms on architectural plans. somewhere I have a little lisp I wrote that would take an intial value, convert it to text, put a box around it and create it at a point picked off the screen.
if memory serves, it could handle a prefix or suffix with a little tweaking, and it would increment the number and present the next number in sequence as a default.
so, I could start with, say R101 and by repeating the command the default would be R102, and so on. get to the second floor and replace the default with 201 and the whole thing starts over.
if it sounds like we are getting close, I could look up the code for you, maybe even do the tweaking, for a nominal fee..... :)
(serious about the "maybe", kidding about the "nominal fee")
roy
Reply to
Roy Knapp
Yes, that wouild be very useful. I'm aleady using a rect. box around the physical address. But it would be great not to have to have to enter in an eight digit number.......300 time.
thanks, Dennis
snipped-for-privacy@charter.net make it into a tree to respond.
Reply to
Dennis
Dennis,
You're tco clever for me today.
I'll just post some code:
the original routine ==>
(defun C:rmno ( / pt d d2 r1 r2 r3 r4 oldpl oldsnap new_num txt) (if (= count nil) (setq count (getint "Starting Room Number: " ) ) (setq count (+ count 1) ) ) (setq pt (getpoint "Text Location: " ) d (* (getvar "textsize") 0.8) d2 (* d 1.1) r1 (polar (polar pt pi d2) (* pi 1.5) d) r2 (polar (polar pt 0 d2) (* pi 1.5) d) r3 (polar (polar pt 0 d2) (* pi 0.5) d) r4 (polar (polar pt pi d2) (* pi 0.5) d) oldpl (getvar "plinewid") oldsnap (getvar "osmode") txt (itoa count) new_num (getstring (strcat "\nNew Number :")) ) (if (/= new_num "") (progn (setq txt new_num count (atoi txt) ) ) ) (setvar "osmode" 0 ) (setvar "plinewid" 0 ) (command "text" "mc" pt "0" txt ) (command "pline" r1 r2 "a" r3 "l" r4 "a" r1 "") (setvar "osmode" oldsnap) (setvar "plinewid" oldpl ) (princ) )
AND A HASTY REWRITE TO ACCOMMODATE AN EIGHT DIGIT NUMBER ===>
(defun C:rmno ( / pt d d2 r1 r2 r3 r4 oldpl oldsnap new_num txt) (if (= count nil) (setq count (getint "Starting Room Number: " ) ) (setq count (+ count 1) ) ) (setq pt (getpoint "Text Location: " ) d (* (getvar "textsize") 0.8) d2 (* d 4.5) r1 (polar (polar pt pi d2) (* pi 1.5) d) r2 (polar (polar pt 0 d2) (* pi 1.5) d) r3 (polar (polar pt 0 d2) (* pi 0.5) d) r4 (polar (polar pt pi d2) (* pi 0.5) d) oldpl (getvar "plinewid") oldsnap (getvar "osmode") txt (itoa count) new_num (getstring (strcat "\nNew Number :")) ) (if (/= new_num "") (progn (setq txt new_num count (atoi txt) ) ) ) (setvar "osmode" 0 ) (setvar "plinewid" 0 ) (command "text" "mc" pt "0" txt ) (command "pline" r1 r2 r3 r4 r1 "") (setvar "osmode" oldsnap) (setvar "plinewid" oldpl ) (princ) )
again, my code is ugly. sorry. you won't find "command" in my better stuff.
caveat emptor: I have always used a fixed text height. I think this routine will bomb if your style is not set to a text style with a fixed height. create one if you are in a hurry, I will rework this routine someday, should I live so long.
send me an email if you like, I think you will be able to beat my encryption:
snipped-for-privacy@XsockXet.XnetX
that is if you remove all capitalized x's
cheers.
roy
Reply to
Roy Knapp
Thanks Roy,
I'll give it a try.
Dennis
Reply to
Dennis

PolyTech Forum website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.