The easiest way to run code at the moment is in .NET.
3 answers
public static void RunAfter(int millisecondTimeout,
System.Threading.ThreadStart method)
{
System.Threading.Thread t = new System.Threading.Thread(() =>
{
System.Threading.Thread.Sleep(millisecondTimeout);
method();
});
t.Start();
}
Then you could do
RunAfter(3000, () => z = 5;);
+1
a source to share