Visual LISP, AutoLISP and General Customization
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Removing Object Property controls with VLISP

3 REPLIES 3
Reply
Message 1 of 4
Anonymous
151 Views, 3 Replies

Removing Object Property controls with VLISP

Is it not possible to remove the Controls in the Object Properties toolbar.
I don't use Lineweight or Plotstyle and wanted to remove this
programatically because I Format my HD so much I don't want to edit the mns
file everytime. The following code should work.

(if (not(vl-catch-all-error-p (setq AcadMenu(vl-catch-all-apply
'vla-item(list (vla-get-menugroups (vlax-get-acad-object)) "ACAD" )))))
(vla-delete (vla-item (vla-item (vla-get-toolbars AcadMenu) "Object
Properties") "Lineweight"))
)

any suggestions.

--
-------------------------------------------------------------------------
Rob Starz
Stardsign cad solutions
iC - AEC Information Center
www.stardsign.com/aecic.html
LayerX beta testers needed... www.stardsign.com/beta_programs.htm
3 REPLIES 3
Message 2 of 4
Anonymous
in reply to: Anonymous

Just ask this question in discussion group 'autodesk.autocad.2000general'
under Object Property toolbar.
Dave suggested creating a partial menu & you can try his custom menu.

--
danny leong

"Rob Starz" wrote in message
news:D05ED1DCACFEB70B7BCD2CC47696D35A@in.WebX.maYIadrTaRb...
> Is it not possible to remove the Controls in the Object Properties
toolbar.
> I don't use Lineweight or Plotstyle and wanted to remove this
> programatically because I Format my HD so much I don't want to edit the
mns
> file everytime. The following code should work.
>
> (if (not(vl-catch-all-error-p (setq AcadMenu(vl-catch-all-apply
> 'vla-item(list (vla-get-menugroups (vlax-get-acad-object)) "ACAD" )))))
> (vla-delete (vla-item (vla-item (vla-get-toolbars AcadMenu) "Object
> Properties") "Lineweight"))
> )
>
> any suggestions.
>
> --
> -------------------------------------------------------------------------
> Rob Starz
> Stardsign cad solutions
> iC - AEC Information Center
> www.stardsign.com/aecic.html
> LayerX beta testers needed... www.stardsign.com/beta_programs.htm
>
>
Message 3 of 4
Anonymous
in reply to: Anonymous

I searched the 2000 NG and found nothing under Object Property Toolbar.


--
-------------------------------------------------------------------------
Rob Starz
Stardsign cad solutions
iC - AEC Information Center
www.stardsign.com/aecic.html
LayerX beta testers needed... www.stardsign.com/beta_programs.htm
Message 4 of 4
Anonymous
in reply to: Anonymous

By the way, did you go to the right discussion group?
It is dated back to 29 Sept 2001
You can do a search by doing this: / click find icon / find dialog box open
up / make sure the 'Look In' field
direct to 'autodesk.autocad.2000general' / in the 'From' name field type
either 'Danny' or 'Dave' / click ' New Search'
This will search the specified discussion group for topics related to
'Danny' or 'Dave'
You also can search for the 'Subject' field which is 'object property
toolbar'

Anyway this is what I've got from Dave.

Danny,
It would be much easier to just load a small partial menu using MENULOAD
containing an altered OBJ PROP toolbar definition. Like this:

/
//
//
***MENUGROUP=MYPARTIALMENU


***TOOLBARS
**TB_OBJECT_PROPERTIES
ID_TbObjectP [_Toolbar("Object Properties", _Top, _Show, 0, 1, 1)]
ID_Ai_molc [_Button("Make Object's Layer Current", "ICON_16_MOLC",
"ICON_16_MOLC")]^C^C_ai_molc
ID_Layer [_Button("Layers", "ICON_16_LAYERS",
"ICON_16_LAYERS")]'_layer
[_Control(_Layer)]
ID_LayerP [_Button("Layer Previous", "ICON_16_LAYERP",
"ICON_16_LAYERP")]^C^C_LayerP
//
//
//
(watch the word wrap, every line should start with ID)

Just copy/paste this to a text editor and save as MYPARTIALMENU.mns and put
it in a custom folder which you have added to your acad search path. This
eliminates fiddling with the standard acad menus, keeping backup copies,
etc. You can then just turn off the acad standard OBJ PROP toolbar and turn
on the customized toolbar with View/Toolbars and pick the appropriate menu
in the Menu Groups dropdown on the Toolbar tab. If you want to customize
more of your toolbars, drop down menus etc you would use this or another
partial menu instead of altering the standard acad menus as the time saved
in re-installs and upgrading is well worth the small amount of time to
prepare the partial menus. My motto is "Never Fiddle With Standard Acad
Files!" (no offense meant to Tim's advise though)
:)
Dave
"danny" wrote in message
news:0BD128C0A15CF6D37841625AAECFA002@in.WebX.maYIadrTaRb...
> Thanks Tim,
> Can I reinstate to the original once I edit it?
> "Tim Skene" wrote in message
> news:65A75C834A654A017326D47333330C29@in.WebX.maYIadrTaRb...
> > Edit the ACAD.MNS file and in the toolbars section remove the following
> > items from the Object Properties toolbar:
> >
> > ID_CtrlColor [_Control(_Color)]
> > [--]
> > ID_CtrlLinet [_Control(_Linetype)]
> > [--]
> > ID_CtrlLineW [_Control(_Lineweight)]
> > [--]
> > ID_CtrlPStyl [_Control(_PlotStyle)]
> >
> >
> > The product below has a wide toolbar like the Standard toolbar but with
> the
> > layer drop-down list, and also all the drop-downs as separate toolbars,
if
> > you want to see how to do it.
> >
> > --
> > Tim Skene
> >
> > PRO Menu - The Productivity Toolbox for AutoCAD
> > www.multicim.com/pmenu.html


danny

"Rob Starz" wrote in message
news:25F22E85099AD94844E354D474042EE1@in.WebX.maYIadrTaRb...
> I searched the 2000 NG and found nothing under Object Property Toolbar.
>
>
> --
> -------------------------------------------------------------------------
> Rob Starz
> Stardsign cad solutions
> iC - AEC Information Center
> www.stardsign.com/aecic.html
> LayerX beta testers needed... www.stardsign.com/beta_programs.htm
>
>

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report

”Boost