Identify/Count the Objects/Entities Drawn in Drawing Template SW2001+
Identify/Count the Objects/Entities Drawn in Drawing Template SW2001+
(OP)
Currently i am using Solidworks 2001 Plus.
I would like to know whether it is possible to identify/count all the objects/entites as well as obtain their individual properties that are present in a drawing template using Visual Basic Code (without selecting the objects/entities).
If so what functions needs to be used ? It would be of great help, if a code snippet as an instance can be given
I would like to know whether it is possible to identify/count all the objects/entites as well as obtain their individual properties that are present in a drawing template using Visual Basic Code (without selecting the objects/entities).
If so what functions needs to be used ? It would be of great help, if a code snippet as an instance can be given






RE: Identify/Count the Objects/Entities Drawn in Drawing Template SW2001+
In short, you will use ModelDoc.GetFirstView to obtain the drawing template. Once you have the Drawing View object, you can use all of the Get... methods to obtain each drawing object. Once you have those objects, you can obtain the information for each object.
Take a look at the SolidWorks API Help from the SW Help Menu. Use the SolidWorks Objects section to see what objects, methods and properties are available. There is sample code, although sometimes lacking, that can get you started. If you have a specific question regarding obtaining a particular object or property, let us know.
Good luck...
DimensionalSolutions@Core.com
While I welcome e-mail messages, please post all thread activity in these forums for the benefit of all members.