You could use Kernel#caller to extract this information http://www.ruby-doc.org/core/classes/Kernel.html#M005955
Jarmo On Apr 17, 4:55 pm, Vikas Tulashyam <vtulash...@gmail.com> wrote: > Hi Friends, > I want to get the name of the calling function in our program . e.g. -- > > > > class A > def Calling() > B.caller() > end > > end > > class B > def self.Caller() > > end > end > > Here, I want to print the name of the calling function e.g. Calling() > in the called function e.g. Caller(). Is it possible in Watir/Ruby? > Please give me some solution for this.. > > Thanks > Vikas --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Watir General" group. To post to this group, send email to watir-general@googlegroups.com Before posting, please read the following guidelines: http://wiki.openqa.org/display/WTR/Support To unsubscribe from this group, send email to watir-general-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/watir-general -~----------~----~----~----~------~----~------~--~---