Aviod Multi Instances of Application in CF

G

Guest

I have created an application for my pda using visual basic.net. I have
created shortcut to the start menu. Somehow I want to aviod creating more
than 1 instance of the application even when user click the shortcut more
than once.

I have found from other threads about using "Process" object and it does
work for .net framework. Unfortunately, it is not directly supported by CF.

How should I do?

Thanks in Advance!
 
N

Nino Benvenuti

Hi Keith,

If you are on Pocket PC, .NET CF will prevent multiple instances of your
application from executing(the .NET CF runtime will actually reactivate
the existing process and bring it to the foreground). Alex Feinman has a
blog entry[1] on the topic that can shed more light on how this works.

FYI: If you want to work with processes via .NET CF, check out the
OpenNETCF.Diagnostics.Process[2] class.

hth,
Nino

[1]http://blog.opennetcf.org/afeinman/PermaLink.aspx?guid=EC034858-E071-4DAA-B1BE-0323B7F54B11
[2]http://www.opennetcf.org/library/
 
C

Chris Tacke, eMVP

And just FYI OpenNETCF's SDF 2.0 will have overloads for Application2.Run
that will enforce an application singleton pattern automatically, so even
the CE guys can get this behavior without extra code (other than the added
"true" parameter to Run()).

--
Chris Tacke
Co-founder
OpenNETCF.org
Are you using the SDF? Let's do a case study.
Email us at d c s @ o p e n n e t c f . c o m
http://www.opennetcf.org/donate


Nino Benvenuti said:
Hi Keith,

If you are on Pocket PC, .NET CF will prevent multiple instances of your
application from executing(the .NET CF runtime will actually reactivate
the existing process and bring it to the foreground). Alex Feinman has a
blog entry[1] on the topic that can shed more light on how this works.

FYI: If you want to work with processes via .NET CF, check out the
OpenNETCF.Diagnostics.Process[2] class.

hth,
Nino

[1]http://blog.opennetcf.org/afeinman/PermaLink.aspx?guid=EC034858-E071-4DAA-B1BE-0323B7F54B11
[2]http://www.opennetcf.org/library/
I have created an application for my pda using visual basic.net. I have
created shortcut to the start menu. Somehow I want to aviod creating more
than 1 instance of the application even when user click the shortcut more
than once. I have found from other threads about using "Process" object
and it does work for .net framework. Unfortunately, it is not directly
supported by CF.

How should I do?

Thanks in Advance!
 
G

Guest

When is v2.0 of OpenNetCF likely to be released Chris?



Chris Tacke said:
And just FYI OpenNETCF's SDF 2.0 will have overloads for Application2.Run
that will enforce an application singleton pattern automatically, so even
the CE guys can get this behavior without extra code (other than the added
"true" parameter to Run()).

--
Chris Tacke
Co-founder
OpenNETCF.org
Are you using the SDF? Let's do a case study.
Email us at d c s @ o p e n n e t c f . c o m
http://www.opennetcf.org/donate


Nino Benvenuti said:
Hi Keith,

If you are on Pocket PC, .NET CF will prevent multiple instances of your
application from executing(the .NET CF runtime will actually reactivate
the existing process and bring it to the foreground). Alex Feinman has a
blog entry[1] on the topic that can shed more light on how this works.

FYI: If you want to work with processes via .NET CF, check out the
OpenNETCF.Diagnostics.Process[2] class.

hth,
Nino

[1]http://blog.opennetcf.org/afeinman/PermaLink.aspx?guid=EC034858-E071-4DAA-B1BE-0323B7F54B11
[2]http://www.opennetcf.org/library/
I have created an application for my pda using visual basic.net. I have
created shortcut to the start menu. Somehow I want to aviod creating more
than 1 instance of the application even when user click the shortcut more
than once. I have found from other threads about using "Process" object
and it does work for .net framework. Unfortunately, it is not directly
supported by CF.

How should I do?

Thanks in Advance!
 
G

Guest

Before Christmas is the target.

-Chris


Simon Hart said:
When is v2.0 of OpenNetCF likely to be released Chris?



Chris Tacke said:
And just FYI OpenNETCF's SDF 2.0 will have overloads for Application2.Run
that will enforce an application singleton pattern automatically, so even
the CE guys can get this behavior without extra code (other than the
added
"true" parameter to Run()).

--
Chris Tacke
Co-founder
OpenNETCF.org
Are you using the SDF? Let's do a case study.
Email us at d c s @ o p e n n e t c f . c o m
http://www.opennetcf.org/donate


Nino Benvenuti said:
Hi Keith,

If you are on Pocket PC, .NET CF will prevent multiple instances of
your
application from executing(the .NET CF runtime will actually reactivate
the existing process and bring it to the foreground). Alex Feinman has
a
blog entry[1] on the topic that can shed more light on how this works.

FYI: If you want to work with processes via .NET CF, check out the
OpenNETCF.Diagnostics.Process[2] class.

hth,
Nino

[1]http://blog.opennetcf.org/afeinman/PermaLink.aspx?guid=EC034858-E071-4DAA-B1BE-0323B7F54B11
[2]http://www.opennetcf.org/library/

Keith wrote:
I have created an application for my pda using visual basic.net. I
have
created shortcut to the start menu. Somehow I want to aviod creating
more
than 1 instance of the application even when user click the shortcut
more
than once. I have found from other threads about using "Process"
object
and it does work for .net framework. Unfortunately, it is not directly
supported by CF.

How should I do?

Thanks in Advance!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top