Geeks Talk

Prepare for your Next Interview




I get error "invalid call to function"...

This is a discussion on I get error "invalid call to function"... within the QTP forums, part of the Software Testing category; Hi guys I want to run this vb file if this event occurs... ***file name ******** fire.vbs Sub FireEvent_Example() 'The following example uses the FireEvent method to trigger 'the onpropertychange ...


Go Back   Geeks Talk > Software Testing > QTP

Register FAQ Members List Calendar Mark Forums Read
  #1 (permalink)  
Old 12-22-2006
Expert Member
 
Join Date: Oct 2006
Posts: 690
Thanks: 0
Thanked 49 Times in 41 Posts
JobHelper is on a distinguished road
I get error "invalid call to function"...

Hi guys
I want to run this vb file if this event occurs...

***file name ******** fire.vbs

Sub FireEvent_Example()
'The following example uses the FireEvent method to trigger
'the onpropertychange event on a form.
Browser("Yahoo").page("Yahoo! Mail - The bes").WebElement("html tag:=Form").FireEvent "onpropertychange"
msgbox " User name changed "
End Sub
******************************
Now if i use executefile("fire.vbs") in expert view , then i get error "invalid call to function"... i know because its an event and should be called automatically ...now should I attach this file to object repository or how else I should have this file called when I run the test ?
thanks..any reply would be appreciated...
priyadarshi
727-492-2183

NOTE : This question was asked by priyadarshi786
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 06-23-2008
Junior Member
 
Join Date: Aug 2006
Location: Bangalore
Posts: 7
Thanks: 0
Thanked 1 Time in 1 Post
jitendramishra is on a distinguished road
Re: I get error "invalid call to function"...

Hi,
Can you please recheck how you are calling the Procedure?
Since this not a function, this is a Sub. I think you can not calling the Sub properly.

Can you "Call" to call the Sub
like
Call FireEvent_Example

Let me know if it doesn't work.

Thanks, Jitu
Reply With Quote
Reply

  Geeks Talk > Software Testing > QTP


Thread Tools
Display Modes


Similar Threads

Thread Thread Starter Forum Replies Last Post
Remove an application without "uninstall/Remove" option anushya Windows 7 10-18-2008 02:42 PM
Filling "Date Creation" field with the current day Lokesh M Test Director 1 02-27-2008 08:39 AM
does anybody explain the "novus testing framework?" pputturi Testing Frameworks 2 02-20-2008 02:30 AM
"like" keyword in oracle.. psuresh1982 Oracle 5 12-22-2006 10:19 AM
McAfee launches "TOTAL PROTECTION" Beta Lokesh M Geeks Lounge 0 06-22-2006 08:44 AM


All times are GMT -4. The time now is 06:17 AM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0
Copyright © 2008 GeekInterview.com. All Rights Reserved