Std Delete: Difference between revisions

From FreeCAD Documentation
(Removed Std prefix in Docnav as discussed)
("See also" must be at and of text block)
Line 35: Line 35:


==Scripting== <!--T:12-->
==Scripting== <!--T:12-->

<!--T:13-->
{{Emphasis|See also:}} [[FreeCAD_Scripting_Basics|FreeCAD Scripting Basics]].


<!--T:14-->
<!--T:14-->
Line 49: Line 46:
}}
}}
<translate>
<translate>

<!--T:13-->
{{Emphasis|See also:}} [[FreeCAD_Scripting_Basics|FreeCAD Scripting Basics]].


<!--T:8-->
<!--T:8-->

Revision as of 03:04, 4 August 2021

Std Delete

Menu location
Edit → Delete
Workbenches
All
Default shortcut
Del
Introduced in version
-
See also
None

Description

The Std Delete command deletes selected objects.

Usage

  1. Select one or more objects.
  2. There are several ways to invoke the command:
    • Select the Edit → Delete option from the menu.
    • Select the Delete option from the Tree view context menu or 3D view context menu.
    • Use the keyboard shortcut: Del.

Scripting

To delete an object use the removeObject method of the document object.

import FreeCAD

FreeCAD.ActiveDocument.removeObject("myObjectName")

See also: FreeCAD Scripting Basics.