Author Topic: Plotstamp  (Read 4302 times)

0 Members and 1 Guest are viewing this topic.

ML

  • Guest
Plotstamp
« on: November 19, 2004, 09:07:05 AM »
Has anyone seen the plotstamp in a collection in VBA
Man, I was looking for like 45 minutes yesterday and still couldn't locate it.

Does it exist in there?

Thank you

Mark

hendie

  • Guest
Plotstamp
« Reply #1 on: November 19, 2004, 10:49:39 AM »
I'm sure there was one.
Wasn't there a dvb that listed code for all the events ? I'm sure it was in there. and I can't find it on my system here (2004) ~ have they dropped some files since 2000 ?
I'll keep looking and if I find it I'll post back

ML

  • Guest
Plotstamp
« Reply #2 on: November 19, 2004, 04:23:05 PM »
Thanks Hendie,

I would really appreciate that.

If I come across it, I will do the same

Mark

hendie

  • Guest
Plotstamp
« Reply #3 on: November 26, 2004, 04:25:28 AM »
I couldn't find it.
I thought it was in the Example_events.dvb but that was not the case.
the closest thing I could find was the Acad document BeginPlot event

Code: [Select]
Private Sub AcadDocument_BeginPlot(ByVal DrawingName As String)
     MsgBox "A drawing has just received a request to plot for: " & DrawingName
End Sub

still, I suppose that's a good starting point for a VBA plot stamp

ML

  • Guest
Plotstamp
« Reply #4 on: November 26, 2004, 07:57:23 AM »
Hey  Hendie

I could not find it either.

I suppose with the plot event you could remind the user to turn the plotstamp on but I just find it too hard to beleive that with all of VBA's capablilities that there is no plotstamp.

I have looked in 2 books also and saw nothing.

What I did for now was put plotstamp on at the end of the macro used to insert our title blocks, so it looks like that will have to do for now.

Thanks

Mark

hendie

  • Guest
Plotstamp
« Reply #5 on: November 26, 2004, 10:31:13 AM »
why not just use that event to place your text and details ready for the plot, and use the End Plot event to remove the text you just placed ?

ML

  • Guest
Plotstamp
« Reply #6 on: November 26, 2004, 10:37:30 AM »
To be honest, I wouldn'treally know how to approach it.
I understand drawing level events, but I never quite figured out how to get the event procedure to load with each drawing.

Keith was explaining it to me one day using the acad.rx file but I really never got a chance to get back to it

Mark

TR

  • Guest
Plotstamp
« Reply #7 on: November 26, 2004, 10:58:47 AM »
ML:

In your support directory create a text file called "acad.rx". Open the file with notepad and on the first line type "acadvba.arx".  Now all you have to do is create a dvb file called acad.dvb which will be loaded automatically when AutoCAD starts.

ML

  • Guest
Plotstamp
« Reply #8 on: November 26, 2004, 11:01:48 AM »
Then, just put my Application and Document level events in the acad.dvb firl Tim?

ML

  • Guest
Plotstamp
« Reply #9 on: November 26, 2004, 11:14:48 AM »
That's perfect Tim! It worked like a charm.
I have been meaning to get back to that but it has been so busy lately.

So, if you wanted to these events to work on other users machines, may be it is a good idea to put the two files in a shared directory that we are all pathed to. What do you think?

I don't think it is necessary to keep these files in the support directory, do you?

hendie

  • Guest
Plotstamp
« Reply #10 on: November 26, 2004, 11:15:41 AM »
switch to the VBAide, select the Thisdrawing icon on the left and hit F7 ~ this will bring up the code window for thisdrawing.
in the left dropdown, select AcadDocument and the right hand drop down will automatically list all the events available to thisdrawing. Just select BeginPlot and drop the code to create your plot stamp in there.
Likewise, select the EndPlot and you can place your code to remove the text in there.

ML

  • Guest
Plotstamp
« Reply #11 on: November 26, 2004, 11:17:04 AM »
Hendie,

Getting back to the plotstamp, the problem is how do you get the text that you use in your plotstamp to insert at the same coords as your plotstamp does?

It seems like it may be more work then it is worth

Mark

ML

  • Guest
Plotstamp
« Reply #12 on: November 26, 2004, 11:20:23 AM »
That would be cool if you could use straight forward acad macros in VBA as well.
ie ^C^Cplotstamp;on;

hendie

  • Guest
Plotstamp
« Reply #13 on: November 26, 2004, 11:22:51 AM »
just use the coords that your existing plotstamp goes in at.
the beauty of doing your own is that you can have whatever you want in there. ~ username, time plotted, fate, filename ~ basically whatever you wish to include.
Have a look at the AddText and AddMtext methods

ML

  • Guest
Plotstamp
« Reply #14 on: November 26, 2004, 02:00:56 PM »
Sounds good, I think i will

I also had an interesting thought:

In your plot event (or any event), you could call up and run a menu(.mnc file)

This is probably not a revolutionary idea, but nonetheless it would be interesting.

So, I have a menu called Plotstamp.mnc for example.
In that menu it simply says ^C^Cplotstamp;on;;

In the plot event, you simply have a little routine that loads and runs it.

You could have an Events.mnc file with a multitude of menu macros that could also be called up.

With VBA we could even create, write, run then dump the menu upon calling an event, that would be a neat idea as well

Mark