Author Topic: Strange Request for lisp program  (Read 2900 times)

0 Members and 1 Guest are viewing this topic.

Big G

  • Guest
Strange Request for lisp program
« on: December 01, 2004, 11:58:40 AM »
Hi guys and gals,
Heres hoping someone can answer this for me.

Im trying to create a standard drawing (with title block) for my fellow CAD users. (using it liberally)
I want a routine that will ask them for a drawing title, drawing number, initials, and automatically insert the date on it, and then save itself as the above drawing number into the appropriate folder, checking it doesnt exist already and asking the user to change the drawing number if so.

Similar idea to inserting a block where you define the attributes blahblah, but a bit more to it than i originally thought.

Can anyone help and point me in the right direction??

Big G
Belfast

JohnK

  • Administrator
  • Seagull
  • Posts: 10648
Strange Request for lisp program
« Reply #1 on: December 01, 2004, 12:15:13 PM »
Man im good!

Take a look at this answer: I even made a fancy web page for it. (Except i put someone elses name on the webpage. :?)

Although it dosent use a lisp, i think this might be a viable solution to your problem.

http://afralisp.com/lisp/rtext.htm
TheSwamp.org (serving the CAD community since 2003)
Member location map - Add yourself

Donate to TheSwamp.org

Mark

  • Custom Title
  • Seagull
  • Posts: 28762
Strange Request for lisp program
« Reply #2 on: December 01, 2004, 12:17:22 PM »
Well I don't have a program that does what you want but there's enough code floating around theswamp to get the job done. If it were me I'd use the block approach.

After the user open a new dwg and runs programX
1.  insert block w/ attributes
2.  create a list of attributes for that block
3.  foreach attribute in list, prompt user for value
4.  fetch dir listing of dwg folder
5.  does that dwg exist?
     A  = yes, ask user to change name
     B = no, issue saveas command

something along those lines..............
TheSwamp.org  (serving the CAD community since 2003)

Keith™

  • Villiage Idiot
  • Seagull
  • Posts: 16899
  • Superior Stupidity at its best
Strange Request for lisp program
« Reply #3 on: December 01, 2004, 12:21:18 PM »
Quote from: Se7en
Man im good!

Take a look at this answer: I even made a fancy web page for it. (Except i put someone elses name on the webpage. :?)

Although it dosent use a lisp, i think this might be a viable solution to your problem.

http://afralisp.com/lisp/rtext.htm


Nice try Se7en, I'm sure Kenny appreciates that ....
Proud provider of opinion and arrogance since November 22, 2003 at 09:35:31 am
CadJockey Militia Field Marshal

Find me on https://parler.com @kblackie

JohnK

  • Administrator
  • Seagull
  • Posts: 10648
Strange Request for lisp program
« Reply #4 on: December 01, 2004, 12:42:25 PM »
Quote from: Keith
Nice try Se7en, I'm sure Kenny appreciates that ....


lol

Kenny and i have this understanding; He does all the work and i take all the credit.
TheSwamp.org (serving the CAD community since 2003)
Member location map - Add yourself

Donate to TheSwamp.org

ELOQUINTET

  • Guest
Strange Request for lisp program
« Reply #5 on: December 01, 2004, 12:47:12 PM »
you bastards you killed kenny  :wink:

ELOQUINTET

  • Guest
Strange Request for lisp program
« Reply #6 on: December 01, 2004, 01:29:51 PM »
i was just playing around with rtext, never really got into it much. i am trying to incorporate the plot stamp into my template then and have the template be the startup drawing then when the user saves the drawing to the new job folder it will change. the problem i'm having is the box doesn't display after regen but if i do rtedit it shows up. how do i get it to display upon regen??? thanks pretty neat stuff

Big G

  • Guest
Strange Request for lisp program
« Reply #7 on: December 02, 2004, 06:25:13 AM »
WOW!!

Excellent Tutorial on Rtext!! much applause!!
The rext is a good approach, but this will mean having to teach people what is is and how to use it, as they will be doing the drawings. Thats not good!
Is there a way of having a block insert as soon as you open the drawing, which will give you the above options?
It really needs to be fool proof, really!!
So any other ideas will be gladly accepted!!

Big G

SMadsen

  • Guest
Strange Request for lisp program
« Reply #8 on: December 02, 2004, 06:43:10 AM »
Fool proof? Uhoh .. no such thing in this world.

Big G, I think Mark just sketched a useful approach to the problem.

Big G

  • Bull Frog
  • Posts: 415
Strange Request for lisp program
« Reply #9 on: December 02, 2004, 10:18:52 AM »
Had a look at Marks approach, but ive also been scouting around other posts on the forum.
Ive set up (or am trying to) a standard generic title block for all to use. In it ive set up layers, dim styles text sizes blah blah. But, from seeing other posts in the forum methinks me is going the wrong way in doing this.
I have text styles of Notes1-100, Title1-100; 1000;500;1250 all for each, but as you can imagine the drawing is starting to get a bit bigger. And by the time the xref goes in, its even bigger.
Surely the resident geniuses of this forum have devised a simplistic (and standard) approach to Title Blocks?
I thought i seen the light at the end of the tunnel. But it was just someone with a torch bringing me more work.
"You have to accept that somedays youre the pigeon and  somedays youre the statue"