Share

PlanarSketch Object

Derived from: Sketch Object

Description

The PlanarSketch object, situated in 3D space. See the overview articles.

Methods

Name Description
AddArcSlotByCenterPointArc Method that creates an arc slot. The sketch entities represent the sketch slot are returned.
AddArcSlotByThreePointArc Method that creates an arc slot. The sketch entities represent the sketch slot are returned.
AddByProjectingEntity Method that creates a new sketch entity by projecting other entities onto the sketch plane. This method performs the same function as the Project Geometry or Project DWG Geometry command according to the Entity you specified.
AddBySilhouette Method that creates new reference sketch geometry as the silhouette on the input face near the input proximity point.
AddStraightSlotByCenterToCenter Method that creates a straight slot. The sketch entities represent the sketch slot are returned.
AddStraightSlotByOverall Method that creates a straight slot. The sketch entities represent the sketch slot are returned.
AddStraightSlotBySlotCenter Method that creates a straight slot. The sketch entities represent the sketch slot are returned.
BreakLink Method that breaks the link to the source sketch.
CopyContentsTo Method that copies all the contents of the sketch to the \input target sketch.
CopyEntitiesTo Method that copies sketch entities of the sketch to the input target sketch.
Delete Method that deletes the sketch. This method is only valid for sketches that are not used by a feature.
Edit Method that causes the Sketch environment to be invoked with this sketch available for interactive edit.
ExitEdit Causes the Sketch environment to be closed and the user interface to return to the previous environment. This is equivalent to the Return command. This method is only valid in the case where this sketch is open for edit within the user interface.
GetCustomLineType Method that returns information regarding the custom line type in use. The method returns a failure if the return value of the LineType property is not kCustomLineType.
GetReferenceKey Method that generates and returns the reference key for this entity.
ModelToSketchSpace Method that takes a 3D coordinate in model space, projects it onto the sketch plane along the normal of the plane and returns a Point2d object containing the resulting coordinate point in sketch space.
MoveSketchObjects Method that moves a collection of sketch objects by a specified vector. If the Copy argument is set to True, the newly created objects are returned.
OffsetSketchEntitiesUsingDistance Method that offsets a sketch entity or a group of connected sketch entities. In both cases, the base sketch entity is first offset by the specified distance and along the specified direction. The base sketch entity is determined as follows: * If only one sketch entity needs to be offset, it will be treated as the base sketch entity. * If a group of end-to-end connected entities need to be offset, the first entity in the group will be treated as the base sketch entity. If this method successfully offsets the specified input sketch entities, the newly created sketch entities are returned.
OffsetSketchEntitiesUsingPoint Method that offsets a sketch entity or a group of end-to-end connected sketch entities. In both cases, the offset is first applied to the base sketch entity such that the offset of the base sketch entity passes through the specified offset point on the sketch. The shortest distance of this offset point from the original base sketch entity determines the offset distance.
RotateSketchObjects Method that rotates a collection of sketch objects by a specified angle. If the Copy argument is set to True, the newly created objects are returned.
SetCustomLineType Method that sets a custom line type to the curve from the specified .lin file. The method automatically changes the value of LineType property to kCustomLineType.
SetEndOfPart Method that repositions the end-of-part marker relative to the object this method is called from. The argument defines if the end-of-part marker will be positioned just before or just after the object. If the object is contained within another object and is not in the top level of the browser, the positioning of the marker will be relative to the top-level object the calling object is contained within. An example of this case is a sketch that has not been shared and has been consumed by a feature. Another example is a nested work feature.
SketchToModelSpace Method that takes a 2D coordinate in sketch space, and returns a Point3d containing the coordinates of the point in model space.
Solve Method that causes the sketch to solve.
UpdateProfiles Method that updates all the profiles within the sketch.

Properties

Name Description
Adaptive Gets and sets whether the sketch is adaptive or not.
Application Returns the top-level parent application object. When used the context of Inventor, an Application object is returned. When used in the context of Apprentice, an ApprenticeServer object is returned.
AttributeSets Property that returns the AttributeSets collection object associated with this object.
AxisEntity Gets and sets the object that defines the X or Y axis of the sketch plane. The AxisIsX property defines whether it is the X or Y axis, and the NaturalAxisDirection property defines the direction of the axis.
AxisEntityGeometry Property that gets the geometry that describes the axis entity.
AxisIsX Gets and sets if the axis entity defines the X or Y axis. True indicates the axis defines the X-axis.
CheckSumValue Gets sketch checksum value.
CircularPatterns Gets the SketchCircularPatterns collection object.
Color Gets and Sets the color for the sketch.
ConstraintStatus Property that returns an enum indicating the constraint status of the sketch entity, signifying whether it is fully constrained, over constrained, or under constrained.
Consumed Gets whether the sketch is consumed or not.
CopyToFlatPattern Gets and sets whether a sheet metal folded model sketch should be copied over (transposed) to the flat pattern.
DataIO Gets the object through which this sketch's data content can be persisted.
DeferUpdates Gets and Sets whether to defer the solving of the sketch or not.
Dependents Gets the dependent objects of the sketch.
DimensionConstraints Gets the collection of all dimension constraints on the sketch.
DimensionsVisible Gets and sets whether the dimensions on the sketch are visible.
DisabledActionTypes Gets and sets the action types valid for this sketch.
Exported Read-write property that gets and sets whether the object is exported. Objects must be marked for export in order for them to be derived.
GeometricConstraints Property that returns the collection of all geometric constraints on the sketch.
HasReferenceComponent Property that specifies if the object was created as the result of a derived part.
HealthStatus Property that returns an enum indicating the current state of the object.
IsOwnedByFeature Property that returns whether this object is owned by a feature. This property should return True for sketches that are created as a result of an unfold or refold feature.
LineType Gets and Sets the line type override for the sketch.
LineWeight Gets and Sets the line weight override for the sketch.
ModelToSketchTransform Property that returns the transformation from model space to the 2d sketch coordinate space.
Name Gets and sets name of the sketch.
NaturalAxisDirection Gets and sets if the sketch plane X or Y axis is in the same direction as that defined by axis entity. True indicates the axis direction is in the same direction as the axis.
OriginPoint Gets and sets origin of the sketch. When set this property, the valid object can be a WorkPoint, Vertex or SketchPoint.
OriginPointGeometry Property that gets the geometry that describes the origin point.
OwnedBy Property that returns the PartFeature object. This property should return the UnfoldFeature or RefoldFeature object that created the sketch.
Parent Property that gets the parent object from whom this object can logically be reached.
PlanarEntity Gets and sets the planar object that defines the planar object the sketch is to be built on.
PlanarEntityGeometry Property that returns the geometry that describes the plane the sketch is based on.
Profiles Property that returns the Profiles collection object.
ProjectedCuts Property that returns the ProjectedCuts collection object. This collection provides access to the existing projected cut edges in the sketch and provides functionality to create new projected cut edges.
RectangularPatterns Gets the SketchRectangularPatterns collection object.
ReferenceComponent Property that returns the ReferenceComponent that resulted in the creation of this feature.
ReferencedEntity Property that returns the referenced sketch in the cases where this sketch was created as a result of a "derive" operation or copied over to the sheet metal flat pattern from the folded model.
Shared Gets and sets whether the profile is shared or not.
SketchArcs Property that returns the SketchArcs collection object.
SketchBlocks Property that returns the SketchBlocks collection object. Only the first level sketch blocks in the sketch are returned. Use SketchBlock.ChildBlocks property recursively to get sketch blocks at all levels.
SketchCircles Property that returns the SketchArcs collection object.
SketchControlPointSplines Read-only property that returns the SketchControlPointSplines collection object. This collection provides access to the existing control point splines in the sketch and provides functionality to create new control point splines.
SketchEllipses Property that returns the SketchEllipses collection object.
SketchEllipticalArcs Property that returns the SketchEllipticalArcs collection object.
SketchEntities Property that returns the collection of all entities on the sketch, regardless of their type.
SketchEquationCurves Read-only property that returns the SketchEquationCurves collection object. This collection provides access to the existing equation curves in the sketch and provides functionality to create new equation curves.
SketchFixedSplines Property that gets the collection object.
SketchImages Property that returns a collection of all images on the sketch.
SketchLines Property that returns the SketchLines collection object. This collection provides access to the existing lines in the sketch and provides functionality to create new lines.
SketchOffsetSplines Property that returns the collection object. This collection provides access to the existing offset splines in the sketch.
SketchPoints Property that returns the SketchPoints collection object.
SketchSplines Property that returns the SketchSplines collection object.
SketchToModelTransform Property that returns the transformation from the 2D sketch coordinate space to model space.
TextBoxes Gets the TextBoxes collection associated with this Sketch.
Type Returns an ObjectTypeEnum indicating this object's type.
Visible Gets and sets the visibility of the sketch.

Accessed From

HoleFeature.Sketch, HoleFeatureProxy.Sketch, PlanarSketch.ReferencedEntity, PlanarSketches.Add, PlanarSketches.AddWithOrientation, PlanarSketches.Item, PlanarSketchProxy.NativeObject, PlanarSketchProxy.ReferencedEntity, ProjectedCut.Parent, ProjectedCutProxy.Parent, SketchBlockDefinition.ReferencedEntity, SketchBlockDefinitionProxy.ReferencedEntity

Derived Classes

PlanarSketchProxy, SketchBlockDefinition

Samples

Name Description
Delete Face, Boundary Patch and Stitch features Demonstrates creating Face, Boundary Patch and Stitch features.
SurfaceBody Copy This sample demonstrates copying a surface body from one part to another. This is equivalent to the Promote command, but the API is much more flexible. In order for the sample to be self-contained, it creates two parts on the fly that will be used to demonstrate copying a body from one part to another. When copying a body into a part, you provide the surface body and a matrix to define its position in the new part. This sample creates a matrix based on the position of these parts within an assembly.
Copy a sketch This sample demonstrates copying the contents of a sketch into another sketch via the API.
Add a decal feature This sample demonstrates the creation of a decal feature.
Derived Parts and Assemblies This sample demonstrates the use of the API to create derived parts and assemblies.
Using Inventor's error dialog Demonstrates using Inventor's error dialog.
Edit profile of an extrude feature This sample demonstrates editing the profile of an extrude feature.
Create sheet metal face and fold features This sample demonstrates the creation of sheet metal face and fold features.
Create and Edit an Extrude Feature with a pocket This sample demonstrates how to edit an extrude feature. It shows how to create a sketch plane at a specified orientation to existing geometry.
Sketch from Face Silhouette This sample creates a cylindrical solid, creates a new sketch plane and creates some new sketch lines from the actual edges and the apparent (silhouette) edges of the cylinder.
Sketch Edit Orientation This sample demonstrates modifying the orientation of a sketch.
Sketch Share This sample demonstrates setting a sketch so it is shared.
Sketch Add This sample demonstrates the creation of a sketch using the Sketches.Add method.
Sketch Add Oriented This sample demonstrates the creation of a sketch using the Sketches.AddWithOrientation method.
Querying a sketch profile to get regions. This sample demonstrates getting region properties from a sketch profile.
Sketch profile control This sample demonstrates the usage of the Profiles API to control the shape of the profile. The sample creates three concntric circles and creates an extrusion of the region between the inner circles.
Add a punch tool feature This program demonstrates the creation of a punch tool feature. It uses one of the punch features that's delivered with Inventor. It assumes you already have an existing sheet metal part and have selected a face to place the punch feature on. The selected face should be large so there is room for the punch features.
Create sheet metal rip feature This sample demonstrates the creation of a rip sheet metal feature.
Create sheet metal face and cut features This sample demonstrates the creation of sheet metal face and cut features.
Create sheet metal face and flange features This sample demonstrates the creation of sheet metal face and flange features.
Projection - project across parts This sample demonstrates projecting a sketch entity across parts in an assembly. To use the sample, have an assembly open that contains at least two occurrences, (parts only), and run the program.
Sketch Delete This sample demonstrates deleting a sketch.
Sketch Open for Edit This sample demonstrates opening a sketch for edit.
Offset a 2D sketch This sample demonstrates the creation of offsets in 2d sketches. Two ways of creating the offset are shown - one uses a distance and the other uses the input point.
Sketch Lines This sample demonstrates creating lines. It uses all of the various methods to create lines, both singly and as rectangles.
Set Sketch Visibility This sample demonstrates setting the visibility of a sketch.
Create and insert a sketch block definition into a part sketch This sample demonstrates inserting a sketch block into a part sketch.
Create sketch block from an existing sketch This sample demonstrates creating a sketch block from an existing sketch.
Create sketch elliptical arc This sample demonstrates creating an elliptical arc in a sketch and dimensioning its minor radius.
Spline - create NURBS This sample demonstrates the creation of a sketch spline using a geometry definition (a NURB). The API also supports creation of 3D sketch splines in a similar way.
Sketch Spline This sample demonstrates creating and manipulating a sketch spline.
Sweep Feature Add This sample demonstrates the creation of a sweep feature. The profile is a circle, but the path is made up of a 3D sketch and a 2D sketch.

Version

Introduced in version 5

Was this information helpful?