Is there a way to use a "timer" on a form, to perfom an action after closing another?

Hello, I have a form opened, then, open a second form from a different link, is there any way to set something like a timer, so, when this second form is closed, do something on the first one like clicking a button or something like that? is it possible? in C# I would user a thread or timer to evaluate that, but I don’t know if it’s possible in AX, thanks!