Displaying command line window in a tab

I have to display a graphics screen of a simulator that is run through a batch file, in a tab. Is it possible? If yes how might I do so?
Thanks for you time!

Is your problem solved yet? If not take a look at this page http://www.labnol.org/software/tutorials/copy-dos-command-line-output-clipboard-clip-exe/2506/
It might help you
By using a property node you can copy content from clipboard
Besides which, my opinion is that Express VIs Carthage must be destroyed deleted
(Sorry no Labview "brag list" so far)

Similar Messages

  • How to run a command line window from code?

    In an application I need to run a dll file with a few arguements. These arguements can be given in the command line window. The execution of the dll file will return a string that i need to get (for the parsing etc).
    1. How can I open a command line window from the Java code?
    2. How to run commands on it?
    3. How to get the results of the commands from the command line into my program?

    In an application I need to run a dll file with a few
    arguements. These arguements can be given in the
    command line window. The execution of the dll file
    will return a string that i need to get (for the
    parsing etc).
    A dll is used by other programs. It is not possible to run it from the command line.

  • Command line windows

    Hi,
    I am using procedures from for example: ctx_ddl, ctx_doc packages (by my program in Java - swing, jdbc). I have problem with command line windows in Windows XP, because they appear when I execute some procedures. What should I do to hide these windows?
    Regards,
    Paul Krolak

    I just fired up DOS edit and saw the blue screen after years and years... it does have one advantage over (plain unadorned) Notepad though -- indents are carried over to the next line.
    @TP -- I didn't find any sluggishness, and my machine isn't spectacularly fast (P4 2.8 GHz HT with 512+256 mismatched 400 MHz RAM running @ 333 MHz / WinXP SP2).
    db

  • Asus Laptop (G1, G2, G5, G70, G71) OLED display: Command line utility.

    Greetings.
    Yep. You did read the subject line properly. There is a new command line utility in town.
    To be more exact, there are two small utilities that I have designed for this little OLED -display. (Links at the end of this post)
    To anyone still in confusion, let me show you:
    Some Asus laptops comes with this neat little status display, but few softwares around to utilize them.
    Specially when it comes to the Linux operating system.
    What I've made here, is a simple and easy to use command line utility that communicates with the display.
    But it doesn't stay at "simple". It also has a few advanced features, which is described in detail in the README and their --help sections.
    With this utility and a bunch of simple pixmap images, anyone can easily create messages, animations and transitions without the need of deep knowledge of the underlying system.
    This makes it perfect for boot animations, event updates, status changes and alike.
    Short video-demostration:
    http://www.youtube.com/watch?v=2i8Twa4h_iI
    X11 Pixmap Format
    To get starting, you need a set of pictures.
    You should, and is encouraged to create these yourself, and if you do, please share your creations with us here. I will update a list of your creations in this post accordingly.
    These utilities can, at the moment, only read xpm images. Most drawing programs can handle this today so hat shouldn't be a problem.
    There is a preferred format, but other formats are possible:
    *  Colordepth: 1 bit (Monocrome)
    *  Height: 32 pixels
    *  Width: 128 pixels (for G1 and G2) or 256 pixels (for G5, G70, G71 ...)
    There are a few prepackaged XPM images that can be used any way you see fit.
    GIMP is the tool I used to create the pictures and animations.
    Installation.
    To install: Read INSTALL. Keep in mind: 'bin' and 'conf' folder relies on eachother, so they should stay together. I plan to improve this, but that's another story.
    Permissions: Again. Read the 'INSTALL' file. You need rw-access to two class nodes:
    /sys/class/asus_oled/oled_1/picture
    /sys/class/asus_oled/oled_1/enabled
    Doesn't exist??? ... did you read the INSTALL and README?... aw... well.. here's a hint:
    # modprobe asus_oled && ls -l /sys/class/asus_oled/
    The module should already exist, and if you're running Arch Linux on that laptop with the default kernel, it's already loaded.
    The modules comes with the Linux kernel itself (Staging area). Nothing else needed to be done. Isn't that awesome?
    If you happen to run a custom kernel, reconfigure it and activate 'asus_oled' as a module. Recompile, install and eat icecream.
    (Icecream part is very important)
    Quickstart.
    Once you created your awesome xpm image, you want it to live on the OLED display. This is the command:
    $ asus_oled-ctl --static-picture My-Awesome-128x32-Pic.xpm
    Explanation: '--static-picture' just simply converts and loads a picture onto the display and exits. Nothing fancy really.
    You haven't created a picture yet? .... horrible drawing skills? ...
    Well ... *sigh* ... Try one of the prepacked pictures then. 128x32_archlinux-logo1.xpm should suffice.
    You find it under pictures/logos/
    Success? Yay! Have some more icecream!
    Next thing you might be interested in, is animations.
    Animations is pretty much just a series of static images inserted one after another in a rapid manner.
    So get to it and convert the whole Star Wars saga to a series of 128x32 monocrome XPM pictures...
    ... or just make a short animation of your liking... and SHARE IT!
    Need a neat command to show your animation skills on the display? Here it is:
    (NOTE: There's a bug that causes this utility to have serious trouble with spaces in paths and files. I'm aware of it. Just avoid spaces for now... )
    $ asus_oled-ctl --cycle 50,10 path/to/my/awesome/animation/*
    Explanation: '--cycle' cycles through all the pictures it's given. The argument '50,10' tells it to delay each frame 50 milliseconds, and loop through them 10 times.
    If you instead wanted one loop instead of 10 and decrease the speed to 100 milliseconds per frame? Just change it accordingly:
    $ asus_oled-ctl --cycle 100,1 path/to/my/awesome/animation/*
    Still a bit confused on how the animations should be set up?
    Have a look at the prepacked examples found under pictures/animations/
    Hey! why not test one of the examples out:
    $ asus_oled-ctl --cycle 50,10 pictures/animations/Arch-ripple_loop/*
    Want it to be endless? Set the loop part to 0, and it will loop forever, or until you run out of power. (You can hit CTRL+C to interrupt)
    $ asus_oled-ctl --cycle 50,0 pictures/animations/Arch-ripple_loop/*
    You might have noticed it took a few seconds before the animation started from the point you hit [Enter]. (And that it took some CPU to do it)
    It's because the utility have to convert the images to a more fitting format before it goes ahead.
    Fortunately, there's a remedy to that delay. It's called cached slots. What it means is that one can tell the utility to store the converted animation data in a storage slot for later use.
    Here's how to do it:
    Step 1: Convert your awesome animation, and store it into a named cache-slot called 'MyAwesomeAnimation'.
    $ asus_oled-ctl --generate-cache MyAwesomeAnimation path/to/my/awesome/animation/*
    It will crunch your pictures for a few seconds, and then exit normally.
    Wait.... WHAT??? ... You did convert Star Wars whole saga?... Wow!!!... That will take an eternity to crunch through... =O
    Once it's done (Hopefully this site still lives when it is) we can now see what cache slots we have in the storage:
    $ asus_oled-ctl --show-cache
    There's your Star Wars saga... *erh*.. awesome animation. If you did a full install, you might notice a few other slots too. You can test em out if you'd like.
    Now to play that cached animation:
    $ asus_oled-ctl --cycle 50,5,MyAwesomeAnimation
    Notice how the animation starts almost instantly this time. That's what cache is for.
    Want to delete any of thos annoying and horrible slots?
    $ asus_oled-ctl --delete-cache MyAwesomeAnimation
    Now a few other commands to try out and discover what they do:
    $ asus_oled-ctl --power off
    $ asus_oled-ctl --power on
    $ asus_oled-ctl --clear
    $ asus_oled-ctl --static-picture pictures/devel/ASUS-logo_reversed.xpm
    $ asus_oled-ctl --help
    $ xpm2asus_oled pictures/logos/128x32_archlinux-logo1.xpm
    $ xpm2asus_oled --output ansi pictures/logos/128x32_archlinux-logo1.xpm
    $ xpm2asus_oled --help
    I hope that I've introduced the utilities for you and awaken your interest in this otherwise useless little display with a neat ASUS-logo on it.
    Now get on to it and create some awesome logos and animations for us all to use.
    I will update this utility every now and then, and hopefully include some of your animations with the package.
    The community's contribution list:
    ... *tumbleweed in the wind* ...
    Links
    Download: https://bitbucket.org/SysGhost/asus-ole … .1.tar.bz2
    Documentation (subject to change): https://bitbucket.org/SysGhost/asus-ole … /wiki/Home
    git: https://bitbucket.org/SysGhost/asus-ole … tility.git
    Read README for details. (It's named README for a reason)
    Update:
    Version 0.1.2 - Minor bugfixes.
    Upcoming: 0.2 - Rewritten in python. Twice as fast.
    Last edited by SysGhost (2012-11-23 14:51:16)

  • Executing jar file on command line [windows]

    Hi,
    I am trying to run .jar file "senthil.jar" . It catures systems screenshot.
    http://sensaran.wordpress.com/2010/06/04/screen-shot-utility-using-air-2-0/
    I am using it in AIR application. I want to execute this file from  command line. I am not sure how to pass command line arguments.
    Currently i am trying to do it like :  java -jar senthil.jar
    I need to provide a parameter as "Print Screen"
    Its corresponding Flex Code is :
                var arg:Vector.<String> = new Vector.<String>;
                arg.push("-jar");
                arg.push(File.applicationDirectory.resolvePath("senthil.jar").nativePath);
                 var file:File = new File();
                file = file.resolvePath(javaPath.replace(/\//g, File.separator));
                var npInfo:NativeProcessStartupInfo = new NativeProcessStartupInfo();
                npInfo.executable = file;
                npInfo.arguments = arg;
                nativeProcess = new NativeProcess();
                nativeProcess.start(npInfo);
                nativeProcess.standardInput.writeMultiByte("Print Screen" + "\n", "utf-8");
    Thanks

    Did you give the -jar option with javaw? And the "%1"? See the file associations of some other extensions for example of how to do this
    For example on my machine,
    W:\>assoc .mp3
    .mp3=Winamp.File
    W:\>ftype Winamp.File
    Winamp.File="C:\Program Files\Winamp\Winamp.exe" "%1"Now I can
    start song.mp3Or doubleclick on mp3 file in explorer to open it in winamp.

  • Display command line output

    In my program LabVIEW calls an executable using a batch file and this executable returns a string. Is there a way for LabVIEW to be able to view this output string?

    hi
    I do not know how your batch files run, but you should get it run properly (with "wait until completion = False) before setting it to TRUE.
    If your batch files do not even run correctly (with "wait until completion = False), it will hangs when your run the system exec.vi (with "wait until completion = TRUE).
    Hope this is not too confusing....
    ... as it's late now... and Zzzzz..
    Ian F
    Since LabVIEW 5.1... 7.1.1... 2009, 2010
    依恩与LabVIEW
    LVVILIB.blogspot.com

  • Linux: Pipe to stdout displays on the command line, but does not redirect to file

    Hello all,
    Several years ago, I was given the task of making a LabVIEW application run from the Linux command line with arguments.
    Now I have the same task, and I naively thought, "Sure, no problem."  So, for my stdout output, I used something very similar to the following:
    It seems to work fine in a compiled application, as it always has, and the prescribed string appears on the command line window.  However, the person testing the functionality here remarked that he couldn't successfully redirect output to a file.
    For example:
    If my compiled binary is "LabVIEW_executable", let's say it is called in the following manner:
    /foo/bar> ./LabVIEW_executable >foo.txt
    Since the desired output appears on the command line, you'd intuitively think that it would also appear in foo.txt, but it does not.  After tinkering for a while and coming up with very little in the way of search results, I thought I'd ask here.
    Has anyone ever done this before?
    I am very grateful for any assistance.
    Regards,
    Jim

    Ahhh, thanks a lot!
    Whoops.  Looks like I made a novice mistake.
    Nice icon, by the way. 

  • Passing command line unicode argument to Java code

    I have to pass command line argument which is Japanese to Java main method. If I type Unicode characters on command-line window, it displays '?????' which is OK, but the value passed to java program is also '?????'. How do I get the correct value of argument passed by the command window? Below is sample program which writes to a file the value supplied by command line argument.
    public static void main(String[] args) {
    String input = args[0];
    try {
    String filePath = "C:/Temp/abc.txt";
    File file = new File(filePath);
    OutputStream out = new FileOutputStream(file);
    byte buf[] = new byte[1024];
    int len;
    InputStream is = new ByteArrayInputStream(input.getBytes());
    while ((len = is.read(buf)) > 0) {
    out.write(buf, 0, len);
    out.close();
    is.close();
    } catch (Exception e) {
    e.printStackTrace();
    }

    To clarify a little:
    If the "command line" means a console opened from the operating system, then the problem is that your machine's operating system can't handle the Unicode characters you want (at least, not in the console mode). If you can't configure the machine to accept Unicode on the command line, you'll have to investigate some other means of passing the argument to your app, as the other poster mentioned.

  • Command line hangs when starting OC4J with MapViewer

    Hello,
    I have a simple development setup with a stand-alone oc4j instance installed via the MapViewer Quick Start Kit, on an 11g database, on a Windows XP workstation.
    The problem: When I start the oc4j instance everything seems to start up successfully - the AS Control, the MapViewer EAR, etc.., but the command line window hangs after the last command is executed. It does not return to the command prompt. And if I close the Command Prompt window the oc4j instance automatically shuts down. Any thoughts on why this is hanging? Or is this normal behavior? Thank you. The text of the startup is shown below.
    (Oh...and if you have any idea why I am getting a string of [ConverterRule] WARNINGS, please let me know. Thanks.)
    -Dan
    ------- Output below --------
    C:\app\oracle\product\11.1.0\db_1\oc4j_mv\j2ee\home>java -jar oc4j.jar
    WARNING: Code-source C:\app\oracle\product\11.1.0\db_1\oc4j_mv\j2ee\home\applica
    tions\mapviewer\web\WEB-INF\lib\dms.jar (from WEB-INF/lib/ directory in C:\app\o
    racle\product\11.1.0\db_1\oc4j_mv\j2ee\home\applications\mapviewer\web\WEB-INF\l
    ib) has the same filename but is not identical to /C:/app/oracle/product/11.1.0/
    db_1/oc4j_mv/lib/dms.jar (from <code-source> (ignore manifest Class-Path) in MET
    A-INF/boot.xml in C:\app\oracle\product\11.1.0\db_1\oc4j_mv\j2ee\home\oc4j.jar).
    If it contains different versions of the same classes, it will be masked as the
    latter is already visible in the search path of loader mapviewer.web.web:0.0.0.
    WARNING: Code-source C:\app\oracle\product\11.1.0\db_1\oc4j_mv\j2ee\home\applica
    tions\mapviewer\web\WEB-INF\lib\ojdl.jar (from WEB-INF/lib/ directory in C:\app\
    oracle\product\11.1.0\db_1\oc4j_mv\j2ee\home\applications\mapviewer\web\WEB-INF\
    lib) has the same filename but is not identical to /C:/app/oracle/product/11.1.0
    /db_1/oc4j_mv/diagnostics/lib/ojdl.jar (from <code-source> (ignore manifest Clas
    s-Path) in META-INF/boot.xml in C:\app\oracle\product\11.1.0\db_1\oc4j_mv\j2ee\h
    ome\oc4j.jar). If it contains different versions of the same classes, it will be
    masked as the latter is already visible in the search path of loader mapviewer.
    web.web:0.0.0.
    Mar 10, 2009 10:51:19 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(javax.faces.Short,null)
    Mar 10, 2009 10:51:19 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(null,java.lang.Short)
    Mar 10, 2009 10:51:19 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(javax.faces.Byte,null)
    Mar 10, 2009 10:51:19 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(null,java.lang.Byte)
    Mar 10, 2009 10:51:19 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(javax.faces.Integer,null)
    Mar 10, 2009 10:51:19 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(null,java.lang.Integer)
    Mar 10, 2009 10:51:19 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(javax.faces.Long,null)
    Mar 10, 2009 10:51:19 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(null,java.lang.Long)
    Mar 10, 2009 10:51:19 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(javax.faces.Float,null)
    Mar 10, 2009 10:51:19 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(null,java.lang.Float)
    Mar 10, 2009 10:51:19 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(javax.faces.Double,null)
    Mar 10, 2009 10:51:19 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(null,java.lang.Double)
    Mar 10, 2009 10:51:19 AM com.sun.faces.config.rules.ValidatorRule end
    WARNING: [ValidatorRule]{faces-config/validator} Merge(javax.faces.LongRange)
    Mar 10, 2009 10:51:19 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(javax.faces.DateTime,null
    Mar 10, 2009 10:51:19 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(javax.faces.Number,null)
    2009-03-10 10:51:20.500 NOTIFICATION oms root path: C:\app\oracle\product\11.1.
    0\db_1\oc4j_mv\j2ee\home\applications\mapviewer\web\
    09/03/10 10:51:20 mbean domain: mapviewer
    2009-03-10 10:51:20.500 NOTIFICATION OMSConfig mbean regisred.
    2009-03-10 10:51:20.500 NOTIFICATION MapTileServer root path: C:\app\oracle\pro
    duct\11.1.0\db_1\oc4j_mv\j2ee\home\applications\mapviewer\web\
    09/03/10 10:51:20 mbean domain: mapviewer
    2009-03-10 10:51:20.515 NOTIFICATION MCSConfig mbean regisred.
    2009-03-10 10:51:20.515 NOTIFICATION MapViewer server version: Ver1033p5_B081010
    2009-03-10 10:51:20.515 NOTIFICATION using default config file: C:\app\oracle\pr
    oduct\11.1.0\db_1\oc4j_mv\j2ee\home\applications\mapviewer\web\WEB-INF\conf\mapV
    iewerConfig.xml
    2009-03-10 10:51:20.515 WARNING dcsf:true
    2009-03-10 10:51:20.531 WARNING destroying ALL mapmaker instances.
    2009-03-10 10:51:20.531 WARNING dcsf:true
    09/03/10 10:51:20 Oracle Containers for J2EE 10g (10.1.3.1.0) initialized
    2009-03-10 10:51:20.578 NOTIFICATION Spatial Provider shapefileSDP has been regi
    stered.
    2009-03-10 10:51:20.578 NOTIFICATION Map Recycling thread started.
    2009-03-10 10:51:20.593 NOTIFICATION *** Oracle MapViewer started. ***
    2009-03-10 10:51:21.515 NOTIFICATION *** Oracle MapTileServer started. ***
    2009-03-10 10:51:21.531 NOTIFICATION *** Oracle Feature of Interest (FOI) Server started ***
    ---> This is where it hangs up. It just sits here and never returns to the command prompt.

    I guess I've come to the conclusion that it's normal for the command window to remain open while mapviewer is running. I just don't recall that from my previous installations.
    -- considered answered.

  • Command line parameters for al_engine.exe

    If you go to a command line window on a DS server and type al_engine.exe with no parameters it prints "Usage" information.  Some of the parameters it mentions are known to the community (like -XX, -XI, etc).  However there are some which sound pretty interesting, but I can't find any information or examples how it should be used.  Examples:
    -L<list of value> : List of Object Labels from UI (separated by , or ; or space) to filter.
    -Je<XML file> Execute the Installation scenario defined in XML file.
    -jd"datastore delta file in quotes>" : Modify datastore values using "file"
    -Jf, -Ja, -We,  and many more.
    I am particularily interested in -Je functiohnality - it sounds like it can be used to automate deployment.  I am using import/export options to do some automation, but real automation would include deletion of some objects, adding jobs to projects, etc.
    Can anybody help with the documentation/examples?

    The preferred way is to save your workflow as an application and then call usr/bin/open on it. If for some reason you must have the workflow run inside of Automator (not self-contained) then you're looking at some quality time with man osascript. As it happens Apple has removed even the need for Cron for most users. A click to File -> Save As Plug-In -> for iCal handles it from start to finish.
    Edit: I forgot to mention that Automator has its own simple command line utility for running *.workflow files. Check out man automator

  • "java.lang.UnsatisfiedLinkError" happen when I use java.exe in command line

    When I use Eclipse 3.01 to run the program it has any problem.But If I use the command line "java -classpath D:\Java_prj\Java\NativeMethod\out com.bruce.nativemethod.HelloNative",a error message will appear below:
    java.lang.UnsatisfiedLinkError: no ./out/com/bruce/nativemethod/ in java.library.path
         at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1403)
         at java.lang.Runtime.loadLibrary0(Runtime.java:788)
         at java.lang.System.loadLibrary(System.java:832)
         at com.bruce.nativemethod.HelloNative.<clinit>(HelloNative.java:21)My HelloNative.dll and HelloNative.class has all been putted in D:\Java_prj\Java\NativeMethod\out\com\bruce\nativemethod.
    My all source code is here:
    //HelloNative.java
    package com.bruce.nativemethod;
    import java.util.*;
    public class HelloNative{
         public static native void greeting();
         //Load the library
         static {
              System.loadLibrary("./out/com/bruce/nativemethod/HelloNative");
              //System.loadLibrary("HelloNative");
         public static void main(String args[]) {
              HelloNative.greeting();
    //HelloNative.c
    #include "HelloNative.h"
    #include <stdio.h>
    JNIEXPORT void JNICALL Java_com_bruce_nativemethod_HelloNative_greeting(JNIEnv* env,
        jclass cl)
        printf("Hello world!\n");
    //HelloNative.h
    //Generated by javah.exe
    /* DO NOT EDIT THIS FILE - it is machine generated */
    #include <jni.h>
    /* Header for class HelloNative */
    #ifndef _Included_HelloNative
    #define _Included_HelloNative
    #ifdef __cplusplus
    extern "C" {
    #endif
    * Class:     HelloNative
    * Method:    greeting
    * Signature: ()V
    JNIEXPORT void JNICALL Java_HelloNative_greeting
      (JNIEnv *, jclass);
    #ifdef __cplusplus
    #endif
    #endifI thinked the code is not problem.But why I can't not run it use java.exe tool in command line?

    Thanks everybody! My problem has been solved.The path "./out/com/bruce/nativemethod/HelloNative" is right because it can run in Eclipse 3.01.I don't agree use the absolute path.If do so,it may not use in another machine. The problem is when I use the "java -classpath D:\Java_prj\Java\NativeMethod com.bruce.nativemethod.HelloNative" in the command line windows,I have putted it the C:\ directory to excute.laterly,I putted the command in the D:\Java_prj\Java\NativeMethod,the result "Hello world!" is appear.

  • Command Line Arguments Return/Echo

    I am calling a standalone LabVIEW 7.0 based application from the command line passing in user arguments.  This works fine.  However, I would like to output status/strings back to the same command line window that the application was run from.  The best I could do was calling a batch file containing 'Echo' commands from 'System Exec' inside the app but this outputs the data in a new command line window, not the same as the one used to run the app.  Anyone know how to do this?
    This post is the same issue but there was no resolution:
    http://forums.ni.com/ni/board/message?board.id=170&message.id=200786&requireLogin=False
    Thanks,
    Steffan 

    This article Knowledge Base 2C7F28O9: Error 2 (Memory Full) When Using the System Exec VI is the closest I know of that may do what you are looking for. If this or any of its related links do not help than I do not believe that it is possible.
    Vince M
    Applications Engineer

  • Command line questions....

    I really have two questions here.
    First, I have a small server that is very similar to this one I pulled off a tutorial:
    public class MyServer{
    // A bare-bones example: exception handling omitted.
       public static void main( String args[] ){
          ServerSocket serv;
          serv = new ServerSocket( 5150 );
          while ( true ) {
             Socket s;
             s = serv.accept();          // Wait for a connection
             handle_connection( s );  // Got one, now do something!
            s.close();
    } When I run this program from the command line it goes into an infinite loop readily accepting connections.
    For the most part, this is what I want. But how do I gracefully exit the program? Simply closing the command window seems drastic, not to mention the list of exceptions it throws.
    Second question: Once I run my program, is there a way I can close the command line window and log off the computer without killing my program?
    thanks.
    (Running on NT)

    How do you stop the program? You write another program that connects to the same socket and sends a message that both programs agree means "Shutdown". When the server receives this message, it shuts down nicely.
    Now you want to run it as an NT service? I've seen people post links to a third-party package that can run a Java class as an NT service; I didn't note the link but you could probably find it by searching the forums.

  • RTCCTOOL in command line

    Hi,
    on Windows, how can I run RTCCTOOL in command line (windows CMD BOX).
    Thanks.

    Suggest to work with expert who can help you in writing a script which calls SAP transactions and reports from command prompt.
    But I don't see any value addition/worth by calling SAP transactions/reports from command prompt, rather it is easier if you call all the SAPs transactions/reports from SAP screen itself. SAP has its own Gui to communicate with other layers and its very user friendly if you operate in a standard way.
    Suggest you to close this thread if your qurey is resolved.
    Regards,
    Nick Loy

  • How can I load PCL font using command line?

    We have a software that requires a signature font to be uploaded to the printer beforehand.  if the printer power cycles, the font is lost and paper is wasted.  This usually happens when a brown out occurs overnight.
    Our font vendor has a command line windows software that can upload the font to the printer.  It costs 100.00. 
    I'd really love to find a way to upload this file using linux.  The page is generated on linux so i could incorporate the command into that process.
    Anyone know of free software to do this on linux or windows?  or maybe programming documentation?

    i think i found the answer on another site
    http://mdn.morovia.com/kb/Download-Select-Remove-PCL-Fonts-10002.html
    Configuration 2: Network Printer Server
    When the printer is connected to a TCP/IP network directly, the best method is to send commands through lpr command. A TCP/IP device may be identified with a full qualified DNS name, or an IP address. In our test lab, we assigned our network printer a fixed IP address 192.168.1.22, and we use this address in the examples below. Inlpr manual page, it is also referred as Printer Name.
    Another name you will need is Queue Name. The queue names are names assigned to the “processors” in the print server. Many print servers and network printers hardcode their queue names. Some allow you to define your own queue. On HP JetDirect printer servers, the raw PCL queues are named as raw, raw1, raw2 and raw3. In this article we use rawas the queue name.
    Note thatlpr command only accepts 1 file at a time. However, the step1 and step2 commands must be sent in one stream, otherwise the printer discards them altogether. As a result, you will need to merge those three files into one first. On Windows, you can use copy command:
    copy /b C80D.txt +mrvcode39_4pitch.sfp +c5F.txt total.bin
    On Linux/Unix platforms, use cat command:
    cat c80D.txt mrvcode39_4pitch.sfp c5F.txt > total.bin
    Now we can send these files (Windows):
    lpr -S 192.168.1.22 -P raw -ol total.bin lpr -S 192.168.1.22 -P raw -ol data.txt
    You need to replace the IP address, the queue name and the file name with the appropriate ones in your environment.
    On Linux/UNIX platforms, things are more complicated. The configuration varies from platform to platform. Generally you need to set up the printer first. On RedHat Linux, this can be done using printtool. You assign a printer name (queue name) in the configuration, and you use this name in lpr command. Assume that the name is HPPrinter, the lpr command on RH Linux becomes:
    lpr -P HPPrinter -o raw total.bin lpr -P HPPrinter -o raw data.txt

Maybe you are looking for