返回到一个已经打开的应用程序,当用户试图打开一个新的实例应用程序、实例、用户

2023-09-02 10:23:54 作者:夏雨别夕庭。

这一直是我一直无法找出了一段时间的一个问题。 preventing二审是微不足道的,有许多方法,但是,带回了已经在运行过程中是没有的。我想:

This has been a problem that I haven't been able to figure out for sometime. Preventing the second instance is trivial and has many methods, however, bringing back the already running process isn't. I would like to:

最小化:撤消最小化,并把正在运行的实例到前面。 在其他窗口后面:把应用前。

我用这中的语言是VB.NET和C#。

The language I am using this in is VB.NET and C#.

推荐答案

我发现这个code是有用的。它的检测和现有的应用程序的可选活化

I found this code to be useful. It does the detection and optional activation of an existing application:

http://www.$c$cproject.com/KB/cs/cssingprocess.aspx