Ok, I can add forms to modules, show them, close them. Now, if for e.g. I have a timer in the second module, it still runs while I've closed the form. I know this is logical, yet, how do I unload the whole module? I want not any source to continue running taking up resources. In Vb I would write an "unload me", in b4a an "activity.finish". In b4j?
Activity.Finish is equivalent to Form.Close. It will not stop a timer for you. In Android the whole components life cycle is much more complicated. So while the timer keeps on running the events are not raised.
You will need to disable the timer when the form close. If you want to clear all global variables together with the form then you should use a class instead of a static module. Then you can just more remove the reference to the class instance and all its variables will eventually be released.
More the reference?
Anyway, I suspected it should be done manually, it's not a problem.
Irrelevant: Just secs ago, I added a tableView in a form, tried generating members, then everything went red. Removed dimming the view, still red. See attached screenshot.
I have had this too. I have seen it in B4A and B4J. The code still works and runs fine. If you close B4A or B4J and just reopen the project, all is fine again.
Did you just reload the project? You have to close the project and close B4J or B4A. Now reload B4J and then reopen the project. This has worked every time for me. I see this at least once a day.
'Problem' disappeared after creating a new project and reloading the old one. BUT while reloading the old one, I mean before creating a new one, the problem was there.
The procedure was creating a new class, then adding a button. So far so good. Then, I placed a tableView, saved the layout and upon generating members, everything went red.