Xojo Conferences

Platforms to show: All Mac Windows Linux Cross-Platform

FAQ.How to know the calling function?
Answer: On Mac you can use a helper function like this this code:
Public Function CallingFunction() as string
// Query name of calling function of a function

#Pragma BreakOnExceptions false


// raise a dummy exception
dim r as new NilObjectException
raise r

catch x as NilObjectException

// get stack
dim stack() as string = x.Stack

// pick function name and return
dim name as string = stack(2)
Return name

end try
End Function
Notes: You need to include function names in your application.

Feedback, Comments & Corrections

The biggest plugin in space...

MBS Xojo Plugins