c# - Open a Form Dialog after x seconds -


i'm looking impliment method executes potentially lengthy or short task. have 'loading' dialog , needs shown after 3 seconds while allowing main execution go ahead. far i've thought using timer:

        var timer = system.diagnostics.stopwatch.startnew();         var elapsedms = timer.elapsedmilliseconds;          if(elapsedms == 3000)         {            loader.show();         } 

but obvious problem if statement passed. have suggestion how approached?


Comments

Popular posts from this blog

AbotX : How do you create a parallel crawler that stays on and can be added to at run time from new requests -

testing - Detect whether test has failed within fixture -

android - Create single AAR file from multiple modules using Gradle -