c# - System.Windows.Forms.Application' does not contain a definition for 'ExecutablePath -
i using compact framework 3.5 build windows mobile application.i need restart application after saving application settings. tried below one,from how restart c# winform application?
string path = path.getdirectoryname(system.reflection.assembly.getexecutingassembly().getname().codebase); process.start(path, ""); i not getting error,but application not restarting.i checking in simulator.do restart working in mobile simulator.
need solution solve problem.
thanks
try using code access path:
string path; path = system.io.path.getdirectoryname( system.reflection.assembly.getexecutingassembly().getname().codebase); but restart application can utilize runappattime method:
var time = datetime.now.addseconds(3); // immediate restart notify.runappattime(thisname, time); // restart app note although time set 3 seconds restart immediately. have real delay time difference must higher 10 seconds. more on here: http://stackoverflow.com/a/6133136/3330348
c# .net compact-framework
No comments:
Post a Comment