where to place common functions

Ranorex Spy, Recorder, and Studio.
manideep
Posts: 5
Joined: Wed Jan 21, 2015 6:53 am

where to place common functions

Post by manideep » Thu Feb 05, 2015 10:45 am

where to place common functions which we want to use in more than one user code modules and how to call the function is there any need to give reference?

User avatar
odklizec
Ranorex Guru
Ranorex Guru
Posts: 3945
Joined: Mon Aug 13, 2012 9:54 am
Location: Zilina, Slovakia

Re: where to place common functions

Post by odklizec » Thu Feb 05, 2015 11:20 am

Hi,

For example, you can create a new class (let's call it Common.cs), put your functions there and then inherit this class in your modules. Check for example this post...
http://www.ranorex.com/forum/function-l ... tml#p26060

Or this blog post, with even detailed description:
http://www.ranorex.com/blog/custom-smart-actions

Another possibility is using custom dll. I believe some forum members prefer to go this way and it was already discussed in the past. Check for example this post:
http://www.ranorex.com/forum/how-to-use ... tml#p28852
Hope this helps?
Pavel Kudrys
Ranorex explorer at Descartes Systems

Please add these details to your questions:
  • Ranorex Snapshot. Learn how to create one >here<
  • Ranorex xPath of problematic element(s)
  • Ranorex version
  • OS version
  • HW configuration