How to monitor .exe excute progress

Hi, My friends~
I have a java application that call .exe win32 Application to do some work. But .exe inital and execute in Background . this process cost a lot of time. Do someone know how to use ProgressBar and ProgressMonitor monitor this process??

Wait for some suggestion~~~I hope that as well as waiting for the solution, you are researching for yourself?
Obviously, you can't monitor the process directly (it's another process), but you can see its output. If the exe provides progress output you can capture that, parse it, and use it to update a JProgressBar. For example (without exception handling or boilerplate code):
//Set the process running
String cmd = "myexec --verbose";
Process p = Runtime.getRuntime().exec(cmd);
//Capture the output
BufferedReader in = new BufferedReader(new InputStreamReader(p.getInputStream()));
//Read the output and extract any progress info
String line = "";
while ((line = in.readLine()) != null) {
    int progress = myParseProgress(line);
    updateProgress(progress);
// and so on.../k1

Similar Messages

  • How to monitor mavericks download progress

    How do I monitor Mavericks download progress?  I have clicked it several times while downloading and I am not sure if I have restarted the process or not - It has been 90 minutes and still says downloading.  Do I need to restart?

    Thanks Mende;
    I can see incremental blue line movement (1 third downloaded) under the X icon in my tray however when I go to the apps store for purchases....The gray box says Download...very confusing - it has been 2 hrs since I rebooted and started over. I am afraid to hit the download tab in purchases - but - 2 hrs for 5 gb?  Should I wait it out?

  • How do I add a progress monitor to a drag and drop question in captivate 7

    I need to build a quiz. We have spent a lot of time on the style guide and appearance but I am having difficulty adding a progress monitor to my drag and drop questions. How can I do this?

    A Drag&Drop is not a normal question slide, hence that progress indicator is not added, and it wouldn't even be functional.
    Long time ago I explained how to create a custom progress indicator, maybe it can help you: Customized Progress Indicator - Captivate blog

  • How to monitor a writeObject() to send its progress to a JProgressBar

    The thing is I have to write an object to a stream, but the size of the object can go up to 5 mb so I would like to give some feedback to the user.
    I have a JProgressBar but don't know how to figure out the progress made by the writeObject() method. I don't know if this is possible...

    hello,
    I have never thought of this before, but the obvious simple solution is a costum FilterOutputStream that counts the data. Construct the ObjectOutputStream on this filter stream.
    acid

  • How to run .exe files with Virtual PC for Mac

    Hey Guys, I'm new around here and with mac technology as well. Anyway, I have an iMac OS X 10.5.1 Leopard and I've recently purchased the Virtual PC for Mac 7.0.2 software. So I'd like to know how to use this program properly, because I need to run some executable files in my computer. It is confusing for me because I don't know how to get started, and I only get to the part when it says "OS not found, Install an OS on this hard drive".
    Honestly I've no idea of what an OS is or where do I get that. So I'd really appreciate if one of you guys could tell me, step by step, what to do to use Virtual PC properly, and finally learn how to run .exe files on mac.
    Thanks in advance!
    Have a nice day!

    Always nice to see new faces
    Honestly I've no idea of what an OS is or where do I get that.
    This brings up the second part of your problem. The first part is setting up either a proper Virtual Machine program like Parallels or VMfusion, or setting up a Boot Camp partition on your drive.
    http://www.parallels.com/
    http://www.vmware.com/products/fusion/
    OS stands for Operating System. You are running Leopard 10.5.7 as an operating system on your Mac (MacOS X).
    The second part of your problem - You will need a copy of Windows XP or Vista if you want to run Windows on your Mac.
    There is at least one other solution for running Windows programs on a Mac. It's called "CrossOver" by a company named 'Codeweavers'. It's based on a project for "Wine" to be able to run PC programs on a Mac or Linux, without having to buy or install Windows. It works with a narrow subset of Windows programs so you would want to make sure the program you want to run is compatible with CrossOver before you buy it.
    http://www.codeweavers.com/products/cxmac/
    In addition to all the above information, you need to upgrade your Mac to the latest 10.5.7 from 10.5.1. "Software Update" is located under the black Apple icon in the Menu Bar at the top left corner of your monitor. After you are updated you will want to update your Profile here so that it shows the proper OS version.
    With your level of experience with MacOS X and the Windows OS's you should probably get some help from a local Apple store. They have an appointment system and do offer many types of help and training, and they can offer assistance with choosing the proper programs for you to purchase for your machine.
    You are also welcome to continue to ask questions here, of course. You will want to ask your questions with different issues that come up in different threads so that the answers stay focused on the title of the thread.
    Message was edited by: dechamp to try to be more accurate with a fairly complicated issue...

  • How to monitor DROP USER

    Hi Guys,
    Would anybody suggest me how to monitor the DROP USER command?
    OS: AIX, Oracle: 11.2.0.2
    CSM

    CSM.DBA wrote:
    I'm extremely sorry for not framing the question properly.
    I mean, Is there any way I can monitor the progress of the DROP USER command.
    To give more details, I have a schema with 500G+ data and I want to drop that schema. No doubt it'll take significant time but how to monitor how it's progressing?
    Using v$session_longops ?
    Aman....

  • How to speed up ProgressEvent.PROGRESS to catch small file uploads?

    Hi there,
    I'm uploading some files to a server. On Mac OSX the Event.COMPLETE listener does not work. It works fine on Windows, but not on OSX.
    So, to test if a file is complete I'm monitoring the ProgressEvent.PROGRESS listener. This works pretty well most of the time on OSX and 100% of the time on Windows.
    My problem is that when I try to upload files that are about 100kb or smaller on OSX, the file apparently uploads so fast that a ProgressEvent is never fired or it's missed and so my script doesn't know the file is complete. I'm testing if bytesUploaded == bytesTotal and small files never seem to register anything in the ProgressEvent. However, files larger than 100kb and up seem to work file and the progress bar moves and I can register when the file is done. This is only OSX.
    Is there way that I can somehow speed up how fast the ProgressEvent is called to listen so it can catch small files' progress?
    Any ideas on how to overcome this? I wish Event.COMPLETE would work on OSX with my host but it simply won't after weeks of testing we can't get it to work so monitoring the ProgressEvent is the only other alternative method of trying to tell whether a file is complete or not. If anyone has any "Plan C" ideas I'm open to that too.
    Thanks!

    Hi there,
    If my memory is not cheating on me then this is a Mac issue. The solution would be to send some additional data, like an empty echo that would force the COMPLETE event to trigger. Try googling for this issue because I'm sure that you'll run over a few articles that can help you out if you insist a bit.
    With best regards
    Barna Biro
    EDIT: Yeah, I found the post on my blog where someone said that he ran over the same problem. http://blog.wisebisoft.com/2009/01/28/simple-flex-file-uploader/ Read Valentijn's reply.

  • How to monitor a specific transaction in Solution Manager ?

    Hi all,
    I have configured the Service Level Reporting and it works correctly.
    But i don't know how to monitor a specific transaction like SM21, DB02, FB01N etc... ?
    In the SL Reports configuration steps, we can configure this option : Select Business Processes For SL Report. I did a lot of tests but it does not work.
    Have i to configure the Business Process Monitoring ?
    Thanks.

    Hello,
    it depends a little on what you want to do. If you use the pure CCMS monitoring with the table ALTRAMONI you get average response time per instance and you only get new measurements once the status changes from green to yellow or red.
    In order to get continuous measurements you should look into Business Process Monitoring and the different documentations under https://service.sap.com/bpm --> Media Libary --> Technical Information. E.g. the PDF Setup Guide for Application Monitoring describes this "newer" dialog performance monitor. Probably you have to click on the calendar sheet in the Media Libary to also see older documents as well. As the Business Process Monitoring integrates with BW (there is also a BI Setup Guide in the Media LIbrary) you can get trendlines there. This BW integration also integrates back with SL Reporting.
    Some guidance for SL Reporting is probably given under https://service.sap.com/rkt-solman but I am not 100% sure.
    Best Regards
    Volker

  • How to monitor an application using JMX

    Hi,
    How can I monitor the portal application running on  portal server by using MBeans (JMX)? For this I need to make a connection between my portal application and  MBean class, How to monitor operations? How can I do that? If anybody has come across the same requirement pls explain me with the implementation details.

    Hello,
    I have done that in a project (not Portal, but pure Java Application, should be no difference), working fine.
    The steps are as follows:
    - create MBean Server (e.g. MBeanServerFactory.createMBeanServer("test");)
    - create your MBeans
    - make them accessible to clients (register the MBeans in the server)
    - query them from clients
    see http://java.sun.com/developer/technicalArticles/J2SE/jmx.html
    for very good explanation including sample source code.
    CSY

  • How to monitor OSD TS failure and get alert or report?

    How to monitor OSD TS failure and get some alert or generate an report?
    We have SCCM 2012 R2 CU1 with MDT 2013.
    I have checked the OSD reports in SCCM and everyone is emty, where do SCCM get data to the what to activate?
    (I thinking of "Task Sequence - Deployment Status" reports)
    I am not sure people read report manually or lock at the MDT monitor view. So best I think that generate an email or incident in Service Manager when an TS fails.
    We do have SCOM, SCSM, SCO.
    Is there anyone that can point what way or what option I have?
    /SaiTech

    Specifically you could use this Status Message Query syntax to monitor your Task Sequences for errors:
    select stat.*, ins.*, att1.*, att1.AttributeTime from SMS_StatusMessage as stat left join SMS_StatMsgInsStrings as ins on stat.RecordID = ins.RecordID left join SMS_StatMsgAttributes as att1 on stat.RecordID = att1.RecordID inner join SMS_StatMsgAttributes
    as att2 on stat.RecordID = att2.RecordID where att2.AttributeID = 401 and att2.AttributeValue = "DOJ200A1" and stat.SiteCode = "DOJ" and att2.AttributeTime >= ##PRM:SMS_StatMsgAttributes.AttributeTime## order by att1.AttributeTime desc
    Just replace DOJ200A1 with the Deployment ID of your Task Sequence and DOJ with your SiteCode.
    If you want to generate an alert if the TS fails then you could run a script that calls a utility (or similar) which sends a pre-configured email to a specified address (as an alternative to Torten's response). This could be placed in the built in error
    logging section of the SCCM integrated MDT Task Sequence when it fails which I assume you are using (right at the bottom, called Gather Logs and StateStore on failure).
    There are heaps of ways of generating an email from a TS and controlling error logging just do a search - as you have Service Manager you could even use your instance of Orchestrator and call a run book in your TS which does the email?
    Cheers
    Damon

  • I started playing Dragon Story on my iPad...how do i sync my progress From my iPad to my iPhone so I can play it on both devices?

    I started playing Dragon Story on my iPad...how do i sync my progress From my iPad to my iPhone so I can play it on both devices?

    bsgoodthing wrote:
    Can't find it on the computer in itunes. I have synced the two but the book still doesn't transfer.
    Turn on computer, open itunes, connecy ipad, click File>Transfer Purchases

  • How to monitor disk space in BW

    can some body help me out on the following issues.
    1)How to monitor disk space in BW?
    2)How can I delete Application logs in BW?

    When I research with DB02 transaction code in BW, I encountered following tables having lot of log , please some body can help me, how to delete the following log data?
    ARFCSDATA     ARFC Call Data (Callers)          
    BALDAT          Application Log: Log data     
    BSRWBSTORE     Storage for binary large objects (Excel)

  • How many monitors can you use on a new imac with GEForce 780m?

    My husband bought a new 27" iMac with the optional GEForce 780m with 4 gig of video ram. He wants to know how many monitors he can run simultaneously, and at what resolutions. He would obviously be using the Thunderbolt ports to do this. I thought this information should be easily found in the technical specs for either the iMac or the video card itself on the NVidia site, but it is not.

    Catherine Gramze wrote:
    Ok, rkaufman. Can he use two 4k monitors in addition to his iMac display? He wants to know what his options are in terms of number of monitors and the resolution. Yes, I know which monitor you buy will be the limiting factor for the actual display, but he has not yet purchased these additional monitors. If thunderbolt allows him to run 3840x2160, how many of them can he run at once at 32 bpp? How many if he chooses 2560x1600 instead?
    To be honest I don't know how many Thunderbolt displays he can run, I would STRONGLY recommend contacting Apple to ask. You can ask the online store (phone number is in upper right of it's home page) or if you have an Apple Store in your area, making an appointment with a business specialist and asking that question.

  • How can I add a Progress bar to show the "render to JPG" progress?

    Hi everyone, I have a button which renders my component to
    JPG.
    How can I attach a progress bar to show the progress of the
    rendering?
    <mx:Button label="render" click="renderasJPEG ()"/>
    public function renderasJPEG( ):void
    convertToImage( component001, new JPEGEncoder( 100));
    private function convertToImage( object:IUICompon ent,
    encoder:IImageEncod er):void
    var base64string: String = ImageSnapshot. encodeImageAsBas
    e64(
    ImageSnapshot. captureImage( object, 72, encoder));
    var variables:URLVariab les = new URLVariables( );
    variables.encoded = base64string;
    variables.type = "jpeg";
    var request:URLRequest = new URLRequest(" script_saveasima
    ge.php");
    request.method = "POST";
    request.data = variables;
    navigateToURL( request, "_blank");
    Thanks in advance.

    Hi,
    I would have thrown a prompt to the user in the renderasJpeg
    function and removed it in last line of convertToImage function.
    Isn't this what you want?
    Hope this helps.

  • How can I use a progress bar in objective c mac

    How can I use a progress bar in objective c mac? I have a code that downloads a file and I want to be able to let the progress bar increase by 1. A bit further on the code (to download the file) it needs to increase again. And so on...
    My code
    -(IBAction) downloadButtonPressed:(id)sender;{
        //get the path to the image that we're going to download
        NSURL *url = [NSURL URLWithString:@"https://www.dropbox.com/s/l6o07m48npxknt4/Cluedo.zip?dl=1"];
        //get the path to documents folder where we're going to save our image
        NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES);
        NSString *DocumentsDirectory = [paths objectAtIndex:0];
        NSString *filePath = [DocumentsDirectory stringByAppendingPathComponent:@"Cluedo.zip"];
        //Download the file to memory
        NSData *data = [NSData dataWithContentsOfURL:url];
        NSError *error = nil;
        //Save it on the Documents directory
        [data writeToFile:filePath options:NSDataWritingAtomic error:&error];
        NSFileManager* fm = [NSFileManager defaultManager];
        NSString* zipPath = filePath;
        NSString* targetFolder = @"/Applications"; //this it the parent folder
        //where your zip's content
        //goes to (must exist)
        //create a new empty folder (unzipping will fail if any
        //of the payload files already exist at the target location)
        [fm createDirectoryAtPath:targetFolder withIntermediateDirectories:NO
                       attributes:nil error:NULL];
        //now create a unzip-task
        NSArray *arguments = [NSArray arrayWithObject:zipPath];
        NSTask *unzipTask = [[NSTask alloc] init];
        [unzipTask setLaunchPath:@"/usr/bin/unzip"];
        [unzipTask setCurrentDirectoryPath:targetFolder];
        [unzipTask setArguments:arguments];
        [unzipTask launch];
        //[unzipTask waitUntilExit]; //remove this to start the task concurrently

    Your code really isn't suitable for a progress bar, not a real one anyway. Your code will spend about 99.9% of its time in the method "dataWithContentsOfURL:url". That is not a method you want to use in the real world. It is only for demos or proof of concept exercises. All network operations should be asynchronous. That gives you the ability to gracefully recover when there is a failure and also to do fancy things like display a progress bar and tell the user when the download is complete.
    Once you get the asynchronous download logic working, then you can worry about the progress bar. The first thing you will need is the size of the file. Without that, all you can ever do is an indeterminate progress bar or spinner. If you have the size of the file, then you can keep track of how much of the file you have downloaded and update your progress bar with the percentage complete. Make sure to throttle it to no more than incrementing by 1% at a time. Otherwise, a large file or a file transferred in many small chunks, would waste too much time updating the progress bar for no change.

Maybe you are looking for

  • ASA 5510 with Cisco 2811 Router Behind it - Not forwarding traffic

    Hi all, Some might know that I have been dealing with an issue where I cannot seem to get forwarded packets to reach their destinations behind an ASA 5510 that has a Cisco 2811 connected directly behind it. Some examples that work. I can SSH into the

  • I have an error message that won't go away and stops me from using any other buttons in the screen.

    I have an error message reading 'item over 1 byte. Connect to a wifi network or use iTunes on your computer to download 'tv show'. When I connect it to iTunes or use a wifi network nothing changes.  The warning remains in place no matter how many tim

  • Multiple key level associations

    Hi, I am getting the below error during the consistency check. Table, X, has multiple key level associations. Can anyone please let me know the reason for the same. Also, when I drag the physical tables from the physical layer to the BMM Layer, there

  • Adobe Photoshop Elements 8.0 wont launch

    I have a ASUS Notebook G72GX Series, Intel Processor, Windows 7.  I've used Adobe all the time from the moment it came out, but now it wont Launch and I'm not sure why, can anyone help me with this problem?

  • How to reset portal password?

    Hi All, Can anybody tell me how to reset portal passowrd. I dont find automatic password generation field when I goto user>search-> modify. Is there any way that i can activate this field on portal.? Thanks, Master.