How to set layer's style and color?

Description

This method adds a layer to this LayerMgr.

Syntax (OLE Automation)

retval = LayerMgr.AddLayer ( layerName, layerDesc, layerColor, layerStyle, layerWidth )

 

Input:

(BSTR) layerName

Layer name

Input:

(BSTR) layerDesc

Description for the new layer

Input:

(long) layerColor

COLORREF value specifying the desired color of items within this layer

Input:

(long) layerStyle

Line style as defined in swLineStyles_e

Input:

(long) layerWidth

Line width as defined in swLineWeights_e

Return:

(int) retval

1 if the layer was created successfully

-------------------

Set pLayerMgr = pDrawing.GetLayerManager

' Create a layer

res = pLayerMgr.AddLayer("myLayer", "Desc", 1227327, 0, 0)

res = pLayerMgr.SetCurrentLayer("myLayer")

-------------------

Target

How to set layer's style and color and thickness?

Thanks

SolidworksApi macros