Solved

Application identity is not set. Application.restart

Posted on 2013-02-07
4
1,387 Views
Last Modified: 2013-02-28
hello all ,
i am getting this exception when
 Application.Restart()
           

Open in new window

any help ?

exception appear when call Application.restart
0
Comment
Question by:AhmedHindy
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 42

Expert Comment

by:sedgwick
ID: 38863121
is it while debugging?
0
 
LVL 143

Expert Comment

by:Guy Hengel [angelIII / a3]
ID: 38863130
indeed ... during debugging (looking at screenshot).

so, you can check out these suggestions I found:
I found that this problem exists only if you untick "Just My Code" under debug options.
in my case I just disabled the InvalidDeploymentException from Debug->Exceptions

you might look into this page for more explanation:
http://social.msdn.microsoft.com/Forums/en-US/csharpgeneral/thread/397c38e4-4306-4791-bed6-f319384c1086
0
 
LVL 42

Expert Comment

by:sedgwick
ID: 38863141
try this approach:

Application.Exit();

Process.Start(Application.ExecutablePath, "/restart" + Process.GetCurrentProcess().Id);

Open in new window


how-do-i-restart-my-c-sharp-winform-application
0
 
LVL 10

Accepted Solution

by:
Monica P earned 500 total points
ID: 38863616
0

Featured Post

Online Training Solution

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action. Forget about retraining and skyrocket knowledge retention rates.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article describes relatively difficult and non-obvious issues that are likely to arise when creating COM class in Visual Studio and deploying it by professional MSI-authoring tools. It is assumed that the reader is already familiar with the cla…
For those of you who don't follow the news, or just happen to live under rocks, Microsoft Research released a beta SDK (http://www.microsoft.com/en-us/download/details.aspx?id=27876) for the Xbox 360 Kinect. If you don't know what a Kinect is (http:…
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…
How to Install VMware Tools in Red Hat Enterprise Linux 6.4 (RHEL 6.4) Step-by-Step Tutorial

739 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question