Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3324572
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T23:26:14+00:00 2026-05-17T23:26:14+00:00

I have two applications: X and Y. X is the main application and it

  • 0

I have two applications: X and Y.
X is the main application and it handles a lot of XML files. It has a history of more than 10 years and half a dozen techniques have been used to store, process and handle these XML files.
Y is a debugging tool that I am developing, which can process and display XML files in a more human-readable form. Basically, it just has a collection of stylesheets that will detect the XML format and if it recognizes the format, it will transform the XML to HTML which is displayed in a TWebBrowser component.

Problem:
When Y is active, I want X to send any XML it proceses to Y for displaying purposes. But only when Y is running! If Y is not running, X just won’t do anything.
The detection of Y needs to be done on any moment and needs to be fast. I’ve considered using TCP/IP communication but the delay caused by a missing Y is just too long. Especially since a lot of XML is processed sometimes. Same problem with named pipes and similar network-based solutions. I need to quickly determine if Y is running and available and if so, send the XML fast and then continue X.
I’ve also considered to make Y a COM-based application or maybe add a COM-based DLL with events that would allow the inter-process communication. The DLL solution would be interesting since it would expose a method to X to upload an XML file, then send an event to Y to process the XML. This seems to be the best option although I would also need to check if the DLL is registered or not. If not, then X can’t even call it!
The application X will also be used by customers who won’t receive Y or the additional DLL so in most cases, the DLL will not be registered. (As I said, it’s meant to help during debugging…)

But maybe there are other options? TCP/IP is too slow, COM is a bit too complex.

X and Y will be running on the same system. Or just X will be on a system and Y is missing completely.


About using memory-mapped files… While practical, I need to keep in mind that most of the times, Y won’t be running thus the MMF will waste memory. XML data can be up to 4 MB in size within X thus having multiple blocks of this size in-memory is a bit overkill. It can be used to send status messages between X and Y but memory is sometimes a bit of a problem with application X. And while a MMF can be connected to a physical file, I’m trying to avoid writing any temporary files altogether.
It’s a good solution, but I fear not good enough.


Some additional explanations are in order, I think. Application X is an application which will be used for several hours, with users doing a lot of actions that translate to lots of XML data that gets processed. Application X is a desktop application that communicates with several web applications (REST), web services (SOAP) and other applications and most of this is through XML.
Application Y is just meant to peek inside the processes that X is running. Basically, X is working for 20 minutes and Y pops up. From that moment on, X should start sending XML to Y until Y disappears again or until X is terminated. In most cases, Y will just be running to capture just a small portion of the running tasks and it’s possibly even started multiple times. But I might be thinking about the whole thing in the wrong direction. Maybe X should be a server with Y registering to it… It’s not a real problem when Y can’t find X. But X not finding Y cannot result in delays or other problems…

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-17T23:26:15+00:00Added an answer on May 17, 2026 at 11:26 pm

    You can do it more simply, since you’re just trying to find out if one app is running from another one. As long as they’re running on the same machine by the same user, you can have X simply use FindWindow() to see if Y is currently running. Just make sure you give Y a meaningful name (in the sample below, it’s TXMLFormatterForm):

    var
      XMLWindow: HWnd;
    begin
      XMLWindow := FindWindow('TXMLFormatterForm', nil);
      if XMLWindow > 0 then
        // Y is running
    end;
    

    You can also use Y’s window caption (title), as long as you’re sure it’s distinct:

    XMLWindow := FindWindow(nil, 'Workshop Alex's XML Formatter');
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a Qt application that has two threads: the main thread that handles
I have two applications written in Java that communicate with each other using XML
I have two applications under tomcat/webapps folder. tomcat/webapps/App1 tomcat/webapps/App2 Both applications share the same
I have two applications in two solutions in VS2008 that share a common dll,
Suppose I have two applications written in C#. The first is a third party
If you have two applications residing on the same server, can you use Server.Transfer
The scenario is this We have two applications A and B, both which are
Here's the thing: I have two applications, written in C++ and running on two
I have two web applications running in the same Tomcat Instance. In one of
I have two web applications in the same server like this: /basedir/app1path/default1.aspx /basedir/app2path/default2.aspx How

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.