AnsweredAssumed Answered

FeatureManager→Why don't InsertTableDrivenPattern

Question asked by Yong Ning on Dec 13, 2014
Latest reply on Dec 15, 2014 by Yong Ning

Table-driven+Pattern.jpg

Why this sentence is true

Set swFeat = swFeatMgr.InsertFeatureTreeFolder2(swFeatureTreeFolder_Containing)

but this sentence is false

Set swFeat = swFeatMgr.InsertTableDrivenPattern(FileName, Pt, False, True)

**************************************************************************************

follow code

**************************************************************************************

Private Sub ss()

   Dim swApp As SldWorks.SldWorks, swModel As ModelDoc2

      Set swApp = Application.SldWorks

      Set swModel = swApp.ActiveDoc

   Dim swFeat As Feature, swFeatMgr As FeatureManager, SwTabFeat As TablePatternFeatureData

      Set swFeatMgr = swModel.FeatureManager

   Dim FileName, Pt '(1) As Double

      Debug.Print swModel.GetPathName

      Path = swApp.GetCurrentMacroPathFolder

      FileName = Path & "\a.SldPTab"

      Pt = Array(10, 10)

      'Set SwTabFeat = SwFeatMgr.InsertTableDrivenPattern(FileName, Pt, False, True)

      'SwFeatMgr.InsertTableDrivenPattern FileName, Pt, False, True

   

      Stop

      Set swFeat = swFeatMgr.InsertTableDrivenPattern(FileName, Pt, False, True)

      Stop

  

End Sub

Outcomes