Welcome to the Java Programming Forums

The professional, friendly Java community. 21,500 members and growing!

The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.


Members have full access to the forums. Advertisements are removed for registered users.

Results 1 to 2 of 2

Thread: Using CreateNamedPipe in Java

  1. #1
    Junior Member
    Join Date
    Sep 2009
    Thanked 0 Times in 0 Posts

    Default Using CreateNamedPipe in Java

    Hi am integrate my java application with a c++ application & i don't have control over the c++ application, already the c++ application integrated with other c++ application using pipes, Now i want to integrate with Java. But i found that java doesn't support CreateNamedPipe().
    Can anyone tell me how to get this done? But am able open,read,write pipes in java but createNamedPipe() causes the problem.

    Thanks in Advance


  2. #2
    Senile Half-Wit Freaky Chris's Avatar
    Join Date
    Mar 2009
    My Mood
    Thanked 105 Times in 90 Posts

    Default Re: Using CreateNamedPipe in Java

    Quote Originally Posted by ejp
    So let's get this straight: you have a C++ named-pipe client application that wants to talk to a named pipe that has to be created by a Java server application.

    If that's the requirement, it's impossible as stated (unless you are prepared to contemplate a lot of JNI).

    If on the other hand the C++ is the server, just open the pipe as usual in Java, with about four backslashes: \\\\server\\pipe\\name ... and use FileInputStream/FileOutputStream to talk to it.

    Oooh look JNI agin, hope the other forum you posted on has answered your question.