Private Function LinkBugToStep() As Boolean ' Link a defect to a run test step Dim linkF As LinkFactory Dim thelink As Link Dim linkableStep As ILinkable Dim BugF As BugFactory Dim Bug As Bug Dim stepsList As List Dim RunF As RunFactory Dim run1 As Run Set RunF = tdc.RunFactory Set run1 = RunF.Item(71) Dim StepF As StepFactory Dim step1 As Step Dim aFilter As TDFilter Dim StepList As List Set StepF = run1.StepFactory Set aFilter = StepF.Filter Set stepsList = aFilter.NewList Set step1 = stepsList.Item(1) Set BugF = tdc.BugFactory Set Bug = BugF.Item(26) Set linkableStep = step1 Set linkF = linkableStep.BugLinkFactory Set thelink = linkF.AddItem(Bug) thelink.Post LinkBugToStep = SUCCESS Exit Function FUNC_ERR: LinkBugToStep = FAILURE End Function