LucaMs Expert Licensed User Longtime User Aug 10, 2014 #1 Can we get, via Reflection or JavaObject, the current "module" name? The aim is to create a routine for logs. I would like to avoid using a variable at module level. ' ModLogs module Public Sub LogW (ModuleName As String, SubName As String, LogMsg As String) ' Main Activity modLogs.LogW(GetModuleName, "Activity_Resume", "Can't do that") Last edited: Aug 10, 2014
Can we get, via Reflection or JavaObject, the current "module" name? The aim is to create a routine for logs. I would like to avoid using a variable at module level. ' ModLogs module Public Sub LogW (ModuleName As String, SubName As String, LogMsg As String) ' Main Activity modLogs.LogW(GetModuleName, "Activity_Resume", "Can't do that")
LucaMs Expert Licensed User Longtime User Aug 10, 2014 #2 Great question, Luca Why don't you try to use "Me" ? Maybe you need a vacation! Upvote 0
LucaMs Expert Licensed User Longtime User Aug 10, 2014 #3 LucaMs said: Great question, Luca Why don't you try to use "Me" ? Maybe you need a vacation! Click to expand... No, it it not so simple Upvote 0
LucaMs said: Great question, Luca Why don't you try to use "Me" ? Maybe you need a vacation! Click to expand... No, it it not so simple
Erel B4X founder Staff member Licensed User Longtime User Aug 12, 2014 #4 Me will not work in static code modules. You can use GetBA method from here: http://www.b4x.com/android/forum/threads/40904/#content It will also not work in static code modules. From this object you can get the class name. Upvote 0
Me will not work in static code modules. You can use GetBA method from here: http://www.b4x.com/android/forum/threads/40904/#content It will also not work in static code modules. From this object you can get the class name.
LucaMs Expert Licensed User Longtime User Aug 12, 2014 #5 I did not understand the hint, but I understand that I will have to use and set a global module variable Thank you, Erel Upvote 0
I did not understand the hint, but I understand that I will have to use and set a global module variable Thank you, Erel