当前位置: 代码迷 >> vbScript >> qc 二次开发 用 VBScript 上载附件
  详细解决方案

qc 二次开发 用 VBScript 上载附件

热度:373   发布时间:2012-11-08 08:48:11.0
qc 二次开发 用 VBScript 下载附件
On Error Resume Next
Set tdconnction = CreateObject("TDApiOle80.TDConnection")
tdconnction.InitConnectionEx "http://lab11:8888/qcbin"
tdconnction.ConnectProjectEx "DEFAULT","QualityCenter_Demo","alex_qc",""
Set BugFact = tdconnction.BugFactory
'根据ID返回需要的附件
Set bugObj = BugFact.Item(21)
Set attachFact = bugObj.Attachments
Set attachList = attachFact.NewList("")
Set attachObj = attachList.Item(1)
Set AttachmentStorage = attachObj.AttachmentStorage
'下载到地址
AttachmentStorage.ClientPath="F:\a\"
AttachmentStorage.Load attachObj.Name,True
if Err=0 Then
wscript.echo "true"
else
wscript.echo "false"
End If
'wscript.echo "结束"
  相关解决方案
本站暂不开放注册!
内测阶段只得通过邀请码进行注册!
 
  • 最近登录:Fri May 25 13:13:11 CST 2018
  • 最近登录:Fri May 25 13:13:11 CST 2018
  • 最近登录:Fri May 25 13:13:11 CST 2018
  • 最近登录:Fri May 25 13:13:11 CST 2018
  • 最近登录:Fri May 25 13:13:11 CST 2018