weld bead API

I try to create weld bead on my model using API and the InsertCosmeticWeldBead2(WeldMode, WeldFromFaceOrEdgeSet, WeldToFaceOrEdgeSet, WeldSize).
the WeldMode should be swCosmeticWeldBeadMode_WeldPath and using 3Dsketch to define WeldFromFaceOrEdgeSet.
I tried the following to define

Dim swSelMgr As SelectionMgr

Set swSelMgr = Part.SelectionManager

Dim weldFromFace() As Sketch

ReDim weldFromFace(0 To 0) As Sketch

Dim weldFromFaceObj As Feature

Dim weldFromFaceObj1 As Sketch

Set weldFromFaceObj = swSelMgr.GetSelectedObject6(1, -1)

Set weldFromFaceObj1 = weldFromFaceObj.GetSpecificFeature2

Set weldFromFace(0) = weldFromFaceObj1

Dim weldFromArray As Variant

weldFromArray = weldFromFace

Dim weldToFace() As Sketch

ReDim weldToFace(0 To 0) As Sketch

Dim weldToFaceObj As Feature

Dim weldToFaceObj1 As Sketch

Set weldToFaceObj = swSelMgr.GetSelectedObject6(1, -1)

Set weldToFaceObj1 = weldToFaceObj.GetSpecificFeature2

Set weldToFace(0) = weldToFaceObj1

Dim weldToArray As Variant

weldToArray = weldToFace

Dim weldObjs As Variant

Dim swFeatureMgr As FeatureManager

Set swFeatureMgr = Part.FeatureManager

weldObjs = swFeatureMgr.InsertCosmeticWeldBead2(1, weldFromArray, weldToArray, 0.01)

SolidworksApi/macros