Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Pure virtual function calll
#1
Not Solved
Hi All,
I'm trying to update the repository and I get the following error:

R6025
-Pure virtual function calll

My function is located in vbs file and called from the action
Code:
Dim  RepositoryFrom
Public Function RenameAllImages(Root)
  
   Set RepositoryFrom = CreateObject("Mercury.ObjectRepositoryUtil")
   RepositoryFrom.Load "H:\temp\test.tsr"
    Dim ImageObj, PageObj, RepositoryFrom, RepositoryTo
     Dim TOCollection, TestObject, PropertiesCollection', Property
    Set TOCollection = RepositoryFrom.GetAllObjects("Test Objects")
    For i = 0 To TOCollection.Count - 1
            Set TestObject = TOCollection.Item(i)
            RepositoryFrom.UpdateObject TestObject
            Set TestObject=nothing
            wait(3)
            If i>2 Then
                Exit for
            End If
    Next
Set TOCollection=nothing
'Set RepositoryFrom=nothing
End Function
I have also tried to place the following code out of the function, but i get the same results

Code:
Set RepositoryFrom = CreateObject("Mercury.ObjectRepositoryUtil")
Reply
#2
Not Solved
I dont know which version of QTP you are using... I had the same problem when I tried working with ObjectRepositoryUtil inside QTP(9.5), Therefore I moved the code external to QTP...in a vbscript file...and removed a call inside QTP... Worked with ObjectRepositoryUtil independent of QTP
however it was working fine with QTP 9.1 inside QTP...
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  virtual objects do not work kawagnes 0 949 08-28-2020, 12:02 PM
Last Post: kawagnes
  Could not create Java virtual machine TangShake 2 8,408 10-26-2017, 11:41 AM
Last Post: walshmagger
  cannot create java virtual machine on QTP 12.02 version richa5685 0 1,852 02-23-2016, 11:18 AM
Last Post: richa5685
  Calling a function in a Test Script from a function library anupam4j 3 5,902 06-26-2015, 12:31 AM
Last Post: babu123
  Virtual objects in QTP nilanjans 1 3,135 11-06-2012, 10:03 AM
Last Post: K Gaurav Varshney

Forum Jump:


Users browsing this thread: 1 Guest(s)