|
代码如下:
' '连接到TD控件
Set tdc = CreateObject("TDAPIOLE.TDConnection")
tdc.InitConnection("http://xxxxx/tdbin")
' If (tdc.Connected = False) Then
'
' End If
'连接到TD,用用户名和密码
call tdc.ConnectProject( "xxx", "xxx", "xxx")
set BugFactory = tdc.BugFactory
'Add a new empty bug
'连接到TD命令,查询出TD的defetid.
Set com = tdc.Command
com.CommandText = "select SQ_SEQ_VALUE from SEQUENCES where SQ_SEQ_NAME='BUG'"
Set recSet = com.Execute
gettdid = CInt(recSet.FieldValue(0))
' msgbox gettdid
'set Bug = BugFactory.AddItem(gettdid)
Set Bug=BugFactory.AddItem(gettdid)
'fill the bug with relevant parameters
Bug.Status = "New"
Bug.Summary = Summary
Bug.Priority = "4-Very High" ' depends on the DB
Bug.AssignedTo = "admin" ' user that must exist in the DB's users list
Bug.DetectedBy = "jiangsf" ' user that must exist in the DB's users list
Bug.Field("BG_DESCRIPTION")= Description
'Post the bug to DB ( commit )
Bug.Post()
TDC.ReleaseConnection()
其中调式到Set tdc = CreateObject("TDAPIOLE.TDConnection")这行的时候报
“General run error” 在调试状态下
使用命令
msgbox err.number
msgbox describeresult(err.number)
最后显示问题为“DLL中出错”
这里不明白这个DLL具体是指什么问题?
不知道各位有没有遇到过这个问题?? |
|