Michael Allison
New member
- Joined
- Aug 8, 2008
- Messages
- 2
- Programming Experience
- Beginner
I'm trying to make a program that is single-instance. Every time a secondary instance of it comes up, I want it to tell the first instance that this happened somehow. I don't know anything about Remoting, or Windows API, and I really need help here, like, just a sample code I could put in or something.
Everyone in our programming group is on vacation, and I'm left with the work of about four people, and I'm inferior to most of them.. If anyone could just show me the way to do this, in a simple, easy to understand manner, I'd be extremely thankful. I've spent over four days doing this one, simple thing.
The reason I want it to tell the first instance that an attempt to open a second one has occured is because my program uses an "Open With..." kind of thing. In other words, they can double-click a file to open it. But if it's single instance, it's not going to try to open it in the same instance automatically. So I need it to check, each time a secondary instance is neutralized, that they weren't trying to open another file; and if they were, I'll use a function to open said file. I can handle all that, but I can't handle the part where I use Inter-Process Communication...
Can someone help, please? Thanks ...
Everyone in our programming group is on vacation, and I'm left with the work of about four people, and I'm inferior to most of them.. If anyone could just show me the way to do this, in a simple, easy to understand manner, I'd be extremely thankful. I've spent over four days doing this one, simple thing.
The reason I want it to tell the first instance that an attempt to open a second one has occured is because my program uses an "Open With..." kind of thing. In other words, they can double-click a file to open it. But if it's single instance, it's not going to try to open it in the same instance automatically. So I need it to check, each time a secondary instance is neutralized, that they weren't trying to open another file; and if they were, I'll use a function to open said file. I can handle all that, but I can't handle the part where I use Inter-Process Communication...
Can someone help, please? Thanks ...