摘要: Function GetObjectClass(ByVal LogicalName)GetObjectClass = ""Dim arrTypesarrTypes = Array("Browser", "Window", "Dialog", "JavaWindow")On Error Resume NextFor each sType in arrTypesErr.ClearSet TempObj = Eval(sType & "(" & LogicalNam 阅读全文
posted @ 2012-07-09 14:35 dushuai 阅读(236) 评论(0) 推荐(0) 编辑
摘要: 第一种方法:Dim iCount, iFoundiCount = 0iFound = 0iFound = inStr(iFound + 1, mainStr, subStr)While iFound <> 0iCount = iCount + 1iFound = InStr(iFound + 1, mainStr, subStr)Wend第二种方法: iCount = UBound(Split(mainStr, subStr))第三种方法: iCount = (Len(mainStr) - Len(Replace(mainStr, subStr, ""))) / 阅读全文
posted @ 2012-07-09 14:25 dushuai 阅读(153) 评论(0) 推荐(0) 编辑
摘要: 1. QTP store OR in binary format which makes it impossible for others to create tools that can help make OR creation easier2. Shared OR can be shared across Tests. But it can't be edited by multiple users at the same time. Shared OR are not like shared excel files where multiple users can update 阅读全文
posted @ 2012-07-09 14:16 dushuai 阅读(156) 评论(0) 推荐(0) 编辑