Jump to content

Welcome to Geeks to Go - Register now for FREE

Need help with your computer or device? Want to learn new tech skills? You're in the right place!
Geeks to Go is a friendly community of tech experts who can solve any problem you have. Just create a free account and post your question. Our volunteers will reply quickly and guide you through the steps. Don't let tech troubles stop you. Join Geeks to Go now and get the support you need!

How it Works Create Account
Photo

Capture VB output from Java


  • Please log in to reply

#1
codecraig

codecraig

    Member

  • Member
  • PipPip
  • 61 posts
Ok,
I basically want to take a VB app (which has no GUI, just does some background work) and writes it output somehow. I can't use MsgBox since that creates pop ups, and I dont want to write to a text file and then read it in from java.

In java I do something like

Process p = Runtime.getRuntime().exec("MyVBApp.exe");
int val = -1;
while ( (val = p.getInputStream().read()) != -1) {
System.out.print((char) val);
}


....that's what I want to do in java...but i cant get anything from the input stream b/c the VB app doesn't write to it.....how can I write to it from VB?

thanks.
  • 0

Advertisements


#2
ratmilk

ratmilk

    Member

  • Member
  • PipPipPip
  • 151 posts
If you wrote the VB app, you could dump it to a text file, then read it via java.
  • 0

#3
codecraig

codecraig

    Member

  • Topic Starter
  • Member
  • PipPip
  • 61 posts
yea I know I could dump it to a file, but as I mentioned in the first post i was looking for some other way than using a text file.
  • 0

#4
ratmilk

ratmilk

    Member

  • Member
  • PipPipPip
  • 151 posts
I don't know, you may have to intercept the window's messages.
  • 0






Similar Topics

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

As Featured On:

Microsoft Yahoo BBC MSN PC Magazine Washington Post HP