This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
I have a Multiple Document Interface (MDI) application written in FORTRAN. It has two child windows, one for displaying some data and another for displaying a trend (graphs).
My problem is I will be knowing only the PID of the above mentioned process from Java end.
How to refer the child window which is displaying data and read the data from it using Java?? I did implemented the above mentioned requirement with normal console application (with no child windows). But it is a window based MDI application now.
I am not doing screen scraping. Actually the process prints out some numbers and text onto screen. I have to read the data printed by the process on the screen and apply some bussiness logic on that. This was simple for a console application by using Java's Process class and getting the input stream of the process.
But the present app is MDI, I am not getting how to point the child window to read the data just by knowing the parent window process id. Can I track the threads (child windows) inside the MDI app?
Any suggestion for this? Thanks in advance [ October 15, 2008: Message edited by: Praveen Kumar Jayaram ]
I don't know if what you are trying to do is possible at all, but if I were you I'd look for some sort of interaction between Fortran and Java (which is surely possible), then I'd check if MDI application has some sort of methods to get/export data somehow (something like public interfaces to external input/output). I highly doubt you can get some data simply starting from the PID of the application process (it would be quite worrying, if you ask to me), although of course I'm not completely sure on this.