Select Task - copy - paste special in diff project

C

Clara11

Hi all

I am trying to read trough my task looking for a certain value in an
enterprise task outline code. When conditions are meet I want to select
the task - copy it - open named project and pastespecial (linked task)
at the end of the project. Everything works fine except - I can't get
the task that meets the criteria to be selected. Here is my code

For Each t In ActiveProject.Tasks
If Not t Is Nothing Then
strDevSysName = t.EnterpriseOutlineCode6
If t.EnterpriseText21 = "C25" Then
**How do I select this task?**
SelectRow - this selects the active row not the task
from the loop
EditCopy
FileOpen Name:="<>\" & strDevSysName & " CAPA
Plan.Published"
ViewApply Name:="Deviation View"
intTCount = ActiveProject.Tasks.Count
SelectRow intTCount + 1
EditPasteSpecial Link:=True, Type:=2,
DisplayAsIcon:=False
ViewApply Name:="GMP View"
FileSave
FileClose
WindowActivate WindowName:="<>\MICS Central Deviation
Plan.Published"
End If
End If
Next t

everything else work fine any and all help - suggestions is greatly
appreciated

thanks
Clara
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top