Table of Contents

Interface IAddinCommandGroup

Namespace
Hymma.Solidworks.Addins
Assembly
Hymma.Solidworks.Addins.dll

represents a solidworks command group that hosts serveral commands

public interface IAddinCommandGroup

Properties

CommandIcons

returns list of command strips for this command group

string[] CommandIcons { get; }

Property Value

string[]

Commands

an array of AddinCommand this group presents

IEnumerable<AddinCommand> Commands { get; set; }

Property Value

IEnumerable<AddinCommand>

Description

Description of this AddinCommandGroup

string Description { get; set; }

Property Value

string

GroupIcon

returns a list of command group icon in standard solidworks sizes

string[] GroupIcon { get; }

Property Value

string[]

HasMenu

if it has menue

bool HasMenu { get; set; }

Property Value

bool

HasToolbar

defines if this command group has toolbar or not

bool HasToolbar { get; set; }

Property Value

bool

Hint

A Hint for this AddinCommandGroup

string Hint { get; set; }

Property Value

string

IconsDir

this is the directory where the icons will get saved to

DirectoryInfo IconsDir { get; set; }

Property Value

DirectoryInfo

IgnorePrevious

Set this to true to prevent SOLIDWORKS from saving the current toolbar setting to the registry, even if there is no previous version.

bool IgnorePrevious { get; set; }

Property Value

bool

IsRegistered

Determines if command Group with the current UserId is registered in the Registry
use IgnorePrevious to decide a new commandGroup is required or not

bool IsRegistered { get; set; }

Property Value

bool

Remarks

If you changed this IAddinCommandGroup in the newer versions of your addin and this method returned true, you should change the UserId .Otherwise you will face compatibility issues

MainIconBitmap

Bitmap object as icon

Bitmap MainIconBitmap { get; set; }

Property Value

Bitmap

Position

position of this command group in command manager 0 is on top and -1 is at the bottom

int Position { get; set; }

Property Value

int

Title

To add a menu item for a CommandGroup to an existing SOLIDWORKS menu, specify the name of a parent menu here.
"&Help\MyApp Title"

string Title { get; set; }

Property Value

string

ToolTip

Tooltip of this AddinCommandGroup

string ToolTip { get; set; }

Property Value

string

UserId

If you change the definition of an existing CommandGroup (i.e., add or remove toolbar buttons), you must assign a new unique user-defined UserID to that CommandGroup.
You must perform this action to avoid conflicts with any previously existing CommandGroup and to allow for backward and forward compatibility of the CommandGroups in your application.
The user ID and the GUID of the CoClass implementing AddinMaker are a unique pair.

int UserId { get; set; }

Property Value

int