Upload a file as Attachments To QC

Function UpLoadAttachToQC(File_Path)
    Set ObjCurrentTest = QCUtil.CurrentTest.Attachments
    Set ObjAttch = ObjCurrentTest.AddItem(Null)
    ObjAttch.FileName = File_Path
    ObjAttch.Type = 1
    ObjAttch.Post
    ObjAttch.Refresh
End Function
 

File_Path=”D:\test.txt”
 

Call UpLoadAttachToQC(File_Path)