If a user starts a second instance of my application I want to pass
the specified parameters to a already running instance of the
application and the terminate the second instance.
I know how to check if a instance is already running but how do I pass
the parameters?
Parameters are normally be filenames, but could also be some switches
like /a,/b etc.
Thomas 4 1835
Hi,
Environment.GetCommandLineArgs() returns a string array of the
command line arguments.
Ken
------------------------
"Tosch" <to**********@swissonline.ch> wrote in message
news:o8********************************@4ax.com... If a user starts a second instance of my application I want to pass the specified parameters to a already running instance of the application and the terminate the second instance.
I know how to check if a instance is already running but how do I pass the parameters? Parameters are normally be filenames, but could also be some switches like /a,/b etc.
Thomas
Ken,
I know that, but how do I pass this to the first instance of the
app???
Thomas
On Sun, 5 Oct 2003 11:44:30 -0400, "Ken Tucker [MVP]"
<vb***@bellsouth.net> wrote: Hi,
Environment.GetCommandLineArgs() returns a string array of the command line arguments.
Ken ------------------------ "Tosch" <to**********@swissonline.ch> wrote in message news:o8********************************@4ax.com.. . If a user starts a second instance of my application I want to pass the specified parameters to a already running instance of the application and the terminate the second instance.
I know how to check if a instance is already running but how do I pass the parameters? Parameters are normally be filenames, but could also be some switches like /a,/b etc.
Thomas
Hi,
Write the info to the registry. Setup a timer to check for the info.
Delete the info after you are done. Or write the info to a file. Setup a
filesystemwatcher to watch for the file. Delete the file when done.
Ken
------------------
"Tosch" <to**********@swissonline.ch> wrote in message
news:m8********************************@4ax.com... Ken,
I know that, but how do I pass this to the first instance of the app???
Thomas
On Sun, 5 Oct 2003 11:44:30 -0400, "Ken Tucker [MVP]" <vb***@bellsouth.net> wrote:
Hi,
Environment.GetCommandLineArgs() returns a string array of the command line arguments.
Ken ------------------------ "Tosch" <to**********@swissonline.ch> wrote in message news:o8********************************@4ax.com.. . If a user starts a second instance of my application I want to pass the specified parameters to a already running instance of the application and the terminate the second instance.
I know how to check if a instance is already running but how do I pass the parameters? Parameters are normally be filenames, but could also be some switches like /a,/b etc.
Thomas
That's an idea, I'll try this.
Thomas
On Sun, 5 Oct 2003 12:57:51 -0400, "Ken Tucker [MVP]"
<vb***@bellsouth.net> wrote: Hi,
Write the info to the registry. Setup a timer to check for the info. Delete the info after you are done. Or write the info to a file. Setup a filesystemwatcher to watch for the file. Delete the file when done.
Ken ------------------ "Tosch" <to**********@swissonline.ch> wrote in message news:m8********************************@4ax.com.. . Ken,
I know that, but how do I pass this to the first instance of the app???
Thomas
On Sun, 5 Oct 2003 11:44:30 -0400, "Ken Tucker [MVP]" <vb***@bellsouth.net> wrote:
>Hi, > > Environment.GetCommandLineArgs() returns a string array of the >command line arguments. > >Ken >------------------------ >"Tosch" <to**********@swissonline.ch> wrote in message >news:o8********************************@4ax.com.. . >> If a user starts a second instance of my application I want to pass >> the specified parameters to a already running instance of the >> application and the terminate the second instance. >> >> I know how to check if a instance is already running but how do I pass >> the parameters? >> Parameters are normally be filenames, but could also be some switches >> like /a,/b etc. >> >> Thomas > This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: zlatko |
last post by:
There is a form in an Access Project (.adp, Access front end with SQL
Server) for entering data into a table for temporary storing. Then, by
clicking a botton, several action stored procedures...
|
by: wesley |
last post by:
Hello,
How do I pass object to the current running process? For example my assembly
is called program.exe. Once program.exe is running sometime I want to call
it again ie:
program.exe /m...
|
by: Dennis Myrén |
last post by:
I have these tiny classes, implementing an interface through which their
method
Render ( CosWriter writer ) ;
is called.
Given a specific context, there are potentially a lot of such objects,...
|
by: Mike Dinnis |
last post by:
Hi,
I've been working through a number of turorials to try to learn more about
retrieving data from a SQL database. I think i've mastered techniques where
i create a sql string in the page and...
|
by: Rune Jacobsen |
last post by:
Hi all,
I am working on my single instance application that now also has a URL
type associated with it, according to the Asynchronous Pluggable
Protocols information from MSDN. Now, if my...
|
by: Sridhar |
last post by:
Hi,
I have created a web application. I have a data access dll to interact
with database. I added this dll as a reference to the web application. Now
let's say if I am calling a function in data...
|
by: william.w.oneill |
last post by:
I have an application that takes a few command line parameters. As
recommended by others in this group, I'm using a named mutex to ensure
that only one instance of the application is running. My...
|
by: Peter Reinhold |
last post by:
Hi All,
I am developing a small utility, and have run into a small challenge.
The util is used for performing operations on a bunch of files, and it
can be triggered from the right-click menu...
|
by: frakie |
last post by:
Hi 'body,
I'm experiencing difficulties on parameter passing.
I wrote a library in last months, and now it crashes few times in a
month because of errors in parameter passing:
using gdb on the...
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
by: emmanuelkatto |
last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud.
Please let me know.
Thanks!
Emmanuel
|
by: BarryA |
last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
|
by: Sonnysonu |
last post by:
This is the data of csv file
1 2 3
1 2 3
1 2 3
1 2 3
2 3
2 3
3
the lengths should be different i have to store the data by column-wise with in the specific length.
suppose the i have to...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers,...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
| |