Method AddBlocks
- Namespace
- OpenCAD2D
- Assembly
- OpenCAD2D.Core.dll
AddBlocks(string, string, IEnumerable<string>)
Makes a palette of a drawing's blocks: one palette named for the drawing, a block tool for each name, taking the drawing as its source, as DesignCenter's Create Tool Palette does.
public CadToolPalette AddBlocks(string name, string file, IEnumerable<string> blockNames)
Parameters
namestringThe palette's name, made unique.
filestringThe drawing's file.
blockNamesIEnumerable<string>The blocks' names, in the order the tools are listed.
Returns
- CadToolPalette
The palette, shown.
Exceptions
- ArgumentNullException
Thrown when the name, the file or the names are null.