PDA

View Full Version : dimtedit switches



Katika
2010-07-25, 11:58 PM
I have been struggling with the need to create a lot of dimension overrides using text over 2nd extension.

While I can do this by altering the dims in properties, it's very rime consuming.

I can add a button to the qat that will align the text left, but cannot figure the quantifier to put on a custom button to do the same over 2nd extension.

Does anyone know, in the script portion " ^C^C_dimtedit \_l" what do I replace "_l" with?

Thanks in advance for any help.

Tom Beauford
2010-07-29, 11:44 AM
I have an Append section in my menu with options which reference a lisp that makes the modifications. There are examples at the bottom of the file.

Katika
2010-07-29, 11:38 PM
Unless I'm reading it wrong, you're using the lisp to add text.

What I am trying to do is set it to have the dimension over the second extension, rather than centred.

I've had a support request in for 7 weeks, and I'm guessing that since they still havent't gotten back to me, a lisp routine is the only way, and I am far to much under the pump to learn lisp atm.

Tom Beauford
2010-07-30, 11:04 AM
Unless I'm reading it wrong, you're using the lisp to add text.

What I am trying to do is set it to have the dimension over the second extension, rather than centred.
I've never seen dimension text placed over an extension. Could you attach a small drawing with the dimension the way you want it? What are you using to "align the text left"?

Katika
2010-08-01, 11:59 PM
Sorry Tom,
it seems I describe my needs poorly. I appreciate your reaponses, they are at least 10 times faster than the active support request I have for this ;)

I was hoping that the button script could be copied and altered on the cui macro.jpg to allow the dimension to be altered as per the dim2nd.jpg

The purpose is to use a baseline dimensions with 0 spacing, to simulate an ordinate dimension.

The reason I need to do this, is that this is for ASD, which has scripts in place that will only allow one dimension style to be used (hence to get the effect I need I have to override that style)

It insists on placing the zero point of the ucs at the end of a shaft, and most shafts have a plate at the end, and I want zero at the end of the combined assembly (ie at the end of the plate)

The inbuilt scripting won't allow me to set the base point, thus using actual ordinate dims doesn't work.

Our factory is complaining about the negative dimensions their system creates, and I am trying to find a less time consuming way of over-riding the difficulites the in-built scripting is causing.

irneb
2010-08-02, 11:01 AM
You can override the horizontal text placement quite easily using Lisp and ActiveX:
(vl-load-com)
(defun c:DimTextHPos (/ en eo)
(while (setq en (entsel "Pick a dimension to toggle its text position (Enter to stop): "))
(setq eo (vlax-ename->vla-object (car en)))
(if (wcmatch (strcase (vla-get-ObjectName eo)) "*DIMENSION")
(vla-put-HorizontalTextPosition eo (rem (1+ (vlax-get eo 'HorizontalTextPosition)) 5))
(princ "\nThat's not a dimension object. Please try again.")
)
)
(princ)
)If you always want it vertically over the 2nd extension line, then change the red highlighted line to this:
(vla-put-HorizontalTextPosition eo 4)0 = Centered, 1 = Horizontal over 1st, 2 = Horizontal over 2nd, 3 = Vertical over 1st.

From this it wouldn't be too difficult to create one which would modify each dim as it's created. Either using a special command, or a reactor ... both should work fine.

irneb
2010-08-02, 11:07 AM
Scratch last, it's even easier to create dims with this override. Just set the DIMJUST sysvar to the needed value 0 to 4. And you do know that you can modify multiple dims at once using the Prop Palette don't you?

Katika
2010-08-02, 11:40 PM
Scratch last, it's even easier to create dims with this override. Just set the DIMJUST sysvar to the needed value 0 to 4. And you do know that you can modify multiple dims at once using the Prop Palette don't you?

Thanks, yeah, I know I can do multiple, which is to an extent how I have been doing it.

Wow, this is a function that in fact actually does work with the ASD coding.
I can now throw in a button on my custom toolbar to toggle modes, and make "fixing" the dimensioning the program does so much easier.

It's a shame that all the switches and toggles have become so buried that with the new help system nobody has any chance of finding them.

Thank you so very much for that sysvar, it's perfect :)