473,734 Members | 2,375 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

External application events

Can one application consume an event from another running application? I
would assume this is what is happen when an application monitors lets say a
port. I have accomplished something similar with remoting but find this to
be a flaky and hard to implement for the user. The two applications with
always be on the same computer.

Regards,
John
Nov 15 '05 #1
4 3136
As both applications would be in different processes, you would need OS IPC
primitives for this. I would probably use a named win32 Event for this, but
would depend on your needs.

--
William Stacey, MVP

"John J. Hughes II" <no@invalid.com > wrote in message
news:eX******** ******@tk2msftn gp13.phx.gbl...
Can one application consume an event from another running application? I
would assume this is what is happen when an application monitors lets say a port. I have accomplished something similar with remoting but find this to be a flaky and hard to implement for the user. The two applications with
always be on the same computer.

Regards,
John

Nov 15 '05 #2

Hi John,

Thanks for posting in this group.
Based on my understanding, you want to make an application that can capture
another application's changes(events) , that is a monitor application.
This is however a big topic, it based on the application you wanted to
monitor.

If another application is a .Net managed application, the recommanded
interprocess communication way is remoting which can also be used on the
same machine.
As you said, you already know how to get this done.

If you wanted to monitor some certain applications such as office series,
you can use automation(add com reference), which is very convenient for you.
For more information, please search automation in MSDN or KB.

If you wanted to monitor a common win32 application which is writen by
yourself, you can P/invoke many of these conventional interprocess
communication technicals such as named pipe, CopyData windows message,
Memory Mapping File, to get this done.(Actually, the named pipe, CopyData
use MMF under the hood).
For more information, please refer to win32 books talk about interprocess
communication.

If you wanted to monitor a win32 application, you know little about, I
think you should use Spy++ or other tools to undertand its mechanism, then
P/invoke remote hook to inject a unmanaged dll into that application's
process space. For more information, please refer to hook in MSDN.

Btw: for the first situation, beside remoting, you also can P/invoke all
those win32 interprocess communication technicals: MMF, named pipe, etc.

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.

Nov 15 '05 #3
Thanks for the response... I will try the named pipe in the other response
first because it will afford me the option of sending data too but I will
certainly keep this in mind.

Regard,
John
"William Stacey" <st***********@ mvps.org> wrote in message
news:uf******** ******@tk2msftn gp13.phx.gbl...
As both applications would be in different processes, you would need OS IPC primitives for this. I would probably use a named win32 Event for this, but would depend on your needs.

--
William Stacey, MVP

"John J. Hughes II" <no@invalid.com > wrote in message
news:eX******** ******@tk2msftn gp13.phx.gbl...
Can one application consume an event from another running application? I would assume this is what is happen when an application monitors lets say
a
port. I have accomplished something similar with remoting but find this

to
be a flaky and hard to implement for the user. The two applications

with always be on the same computer.

Regards,
John


Nov 15 '05 #4
Thanks for the response... I will try the named pipe being the one I am
mostly likely able to accomplish in a short time.

Regards,
John
Nov 15 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
2357
by: knocte | last post by:
Hello. I am a web developer very worried about "bloat code" and "languages mixture". So, since some time, I always try to avoid completely the use of javascript in XHTML/HTML files. This leads to me to hate, also, any event (onload, onchange, ...) instanciated in the element tag itself, like: <input type="text" onkeyup="return doSomething();" /> I would replace this code above with an input element marked with an
24
5252
by: ej1002 | last post by:
Hi I have developed a Windows Application(C# Windows Form) which will get the IFrame Source of the page it is navigating using Webbrowser Control. Now I want do this in ASP.Net web application(C# Web Form). Is there any other method through which I will be able to access the IFrame Source of the page I am navigating to. Also I need to click on some of the links in the page I am navigating. Requirement is to read the data the IFrame source...
6
1704
by: Dmitry Duginov | last post by:
My web application uses resource files to keep localized strings etc. Those resource files prepared by external console program, which extracts this stuff from the database. Is there a way to invoke that program automatically after I hit build (rebuild) button in Visual Studio, before VSS actually trying to build the solution? I'm working with Whidbey beta 2.
0
1350
by: lcifers | last post by:
I have written an application and tested it as a Windows executable. It works fine. The application uses an external COM application to process some existing files. But I can't seem to start that external program correctly. I've found this code: ' Set process parameters Dim myProcess As New System.Diagnostics.Process myProcess.StartInfo.FileName = "notepad.exe" ' Allow the process to raise events
4
2433
by: Paul Fi | last post by:
I want to handle external events from my c# app, especially to events from windows explorer (windows shell) and windows media player how do i go about handling such external events? *** Sent via Developersdex http://www.developersdex.com ***
5
3636
by: snicks | last post by:
I'm trying to exec a program external to my ASP.NET app using the following code. The external app is a VB.NET application. Dim sPPTOut As String sPPTOut = MDEPDirStr + sID + ".ppt" Dim p As New System.Diagnostics.Process 'p.Start(MDEPDirStr & "macrun.exe", sPPTOut) p.Start("C:\WINDOWS\SYSTEM32\CALC.EXE") 'p.Start("C:\WINDOWS\SYSTEM32\macrun.exe", sPPTOut)
2
1313
by: Dan | last post by:
Hi all, I have a quick question about the formatting of external text files. I am trying to make a webpage for a local church that will display what is on in the coming weeks. I have done this using an external text file so that the future users will never have to modifiy the page itself. If left as plain text, it shows on the page in default format. I know I can format the text within the text file using standard HTML, but is
3
4175
by: lookaround | last post by:
Hi everyone, I need some help... I call an external exe (a command-line tool) with Process.Start through this code: try { p = new Process(); p.StartInfo.UseShellExecute = false; p.StartInfo.FileName = ExePath;
1
1610
by: JasonT | last post by:
Hi. I have created a dll in VC++ 08 that exports a CLR windows form class. I call into this dll from an external (closed source, third-party) application to instantiate the form and embed it into the external application window using SetParent(). The problem is, the form runs in the external application window, but the external application no longer updates (renders, responds to close button click, etc.). Now I know the reason is that in...
0
8946
marktang
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8776
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9449
Oralloy
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9182
tracyyun
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8186
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6735
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4550
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4809
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
3
2180
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.