Need very simple ''progress bar'' or a ''Please wait notice'' in javascript

I have a JSF portlet app, made in JSC. It uses remote EJB calls and some calls take a long time to finish. E.g. User clicks a button, some data are gathered, sent to an EJB and the app. is waiting for reply.
For the user it looks like this: Click ... Internet Explorer progress bar flashes, nothing happens for 30s, then the progress bar starts from zero again and loads the next page in 15s.
So I need a very simple notice in the middle of the screen, that will just say "Take a break, don't click the button again, please! ... " and animate a clock, a bar or whatever, maybe disabling the window so the user will not be able to push buttons. (The users are annoying folk!)
The message should dissapear as soon as the next (or the same) page loads.
I've never did javascript, so if anybody has a simple example code, I will be grateful and give him a duke or two. (And I really don't need the AJAX super-components)

Martin, best of luck, i fought this same problem last year.
Even when I got a progress bar on my page, it would not "animate" as IE apparently does not animate gifs after a form is submitted (and before the page is destroyed). I think I eventually got around this by adding an onclick event to my form submit that reset the image.
Best of luck.
Ideally, is there anyway that we can get this IE behavior (page loads, waits for X times, page loads again correctly) fixed? This is highly confusing to my clients.

Similar Messages

  • Need simple progress bar

    Hi...
    I have a GUI which calls methods in different classes.
    There are three long running tasks, which I want to be able to display the progress of.
    Each task MUST finish before the other proceeds, so I don't think it is necessary for more than one thread.
    I want to have a simple "progress bar" pop-up when each task starts, and then disappear when it is finished. Or, have a "progress indicator" on the GUI, which can be reset and started again.
    I have played around with JProgressBars and JProgressMonitors (from this site), but haven't been able to adapt them to the simple needs.
    Is there any hope for what I want to achieve?
    You would have thought this was an easy task, but I'm a broken man!
    Thanks for any help.

    Maybe this example will help.
    If it does may I claim the duke dollars please
    * ProgressDLG.java
    * Created on 23 April 2004, 13:38
    package com.starjar.tests.progress;
    * @author  Peter Henderson
    public class ProgressDLG extends javax.swing.JDialog {
        /** Creates new form ProgressDLG */
        public ProgressDLG(java.awt.Frame parent, boolean modal) {
            super(parent, modal);
            initComponents();
        /** This method is called from within the constructor to
         * initialize the form.
         * WARNING: Do NOT modify this code. The content of this method is
         * always regenerated by the Form Editor.
        private void initComponents() {
            java.awt.GridBagConstraints gridBagConstraints;
            jButton1 = new javax.swing.JButton();
            jProgressBar1 = new javax.swing.JProgressBar();
            jLabel1 = new javax.swing.JLabel();
            getContentPane().setLayout(new java.awt.GridBagLayout());
            setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
            jButton1.setText("Start");
            jButton1.addActionListener(new java.awt.event.ActionListener() {
                public void actionPerformed(java.awt.event.ActionEvent evt) {
                    jButton1ActionPerformed(evt);
            gridBagConstraints = new java.awt.GridBagConstraints();
            gridBagConstraints.gridy = 5;
            getContentPane().add(jButton1, gridBagConstraints);
            gridBagConstraints = new java.awt.GridBagConstraints();
            gridBagConstraints.gridy = 2;
            getContentPane().add(jProgressBar1, gridBagConstraints);
            jLabel1.setText("jLabel1");
            gridBagConstraints = new java.awt.GridBagConstraints();
            gridBagConstraints.gridy = 1;
            getContentPane().add(jLabel1, gridBagConstraints);
            pack();
        private void jButton1ActionPerformed(java.awt.event.ActionEvent evt) {
            jButton1.setEnabled(false);
            Worker w = new Worker();
            w.start();
        class Worker extends Thread {
            public void run() {
                task1();
                task2();
                task3();
                workerComplete();
            private void workerComplete() {
                try {
                    javax.swing.SwingUtilities.invokeAndWait( new Runnable() {
                        public void run() {
                            jButton1.setEnabled(true);
                } catch(Exception e ) {
                    // oh well.
            private void setTaskNameFromWorker(final String taskName) {
                try {
                    javax.swing.SwingUtilities.invokeAndWait( new Runnable() {
                        public void run() {
                            jLabel1.setText( taskName );
                } catch(Exception e ) {
                    // oh well.
            private void setProgressFromWorker(final int progress) {
                try {
                    javax.swing.SwingUtilities.invokeAndWait( new Runnable() {
                        public void run() {
                            jProgressBar1.setValue(progress);
                } catch(Exception e ) {
                    // oh well.
            private void task1() {
                setTaskNameFromWorker("Running Task ONE");
                for(int i=0; i<100; i++) {
                    setProgressFromWorker(i);
                    try{ Thread.currentThread().sleep(25); } catch(Exception e) {}
            private void task2() {
                setTaskNameFromWorker("Running Task TWO");
                for(int i=0; i<100; i++) {
                    setProgressFromWorker(i);
                    try{ Thread.currentThread().sleep(25); } catch(Exception e) {}
            private void task3() {
                setTaskNameFromWorker("Running Task THREE");
                for(int i=0; i<100; i++) {
                    setProgressFromWorker(i);
                    try{ Thread.currentThread().sleep(25); } catch(Exception e) {}
         * @param args the command line arguments
        public static void main(String args[]) {
            new ProgressDLG(new javax.swing.JFrame(), true).show();
        // Variables declaration - do not modify
        private javax.swing.JButton jButton1;
        private javax.swing.JLabel jLabel1;
        private javax.swing.JProgressBar jProgressBar1;
        // End of variables declaration
    }Peter Henderson
    Sales Manager
    Starjar Ltd
    http://www.starjar.com

  • Need to use progress bar in my application

    hello friends,
    Actually i m using jsp filedownload and I am gettting my file in byte array and need to implement a progress bar while downloading file (as IE showing in status bar downloading file size ..% of total file size)...no fake progress bars and no stop gap solutions as like a gif moving with sign "plz wait ..file is downloading "
    plz help how to get this done
    My code
    HashMap result = (HashMap)request.getAttribute("requestParams");
         String type = request.getParameter("type");
         boolean isFile = false;
              if(result != null){
              String successFlag = (String) result.get("");
              String sFileName = null;
              byte[] bFile = null;
              String sContentType = null;
              if(successFlag != null && successFlag.equals("true")){
                   for(int i=0;i<result.size();i++){
                        sFileName = (String) result.get("FILENAME");
                        bFile = (byte[]) result.get("FILEDATA");
                        sContentType = (String) result.get("CONTENTTYPE");
                   response.reset();
                   if(null!=bFile) {
                        if(bFile.length>0){
                             if(sContentType == null || sContentType.equals("")){
                                  response.setContentType( "application/octet-stream" );
                             else response.setContentType(sContentType);
                             response.setHeader("Accept-Ranges", "bytes");
                             isFile = true;
                             response.setHeader("Content-Length", Integer.toString(bFile.length, 10));
                             if(null!=sFileName){
                                  if("view".equals(type)){
                                       if(null!=sFileName)response.setHeader("Content-Disposition","inline; filename=\""+sFileName+"\"");
                                  else{
                                       response.setHeader("Content-Disposition","attachment; filename=\""+sFileName+"\"");
                             ServletOutputStream outs = response.getOutputStream();
                             if(null!=bFile)outs.write(bFile);
                             outs.flush();
                             outs.close();
                             out.clear();
                             out = pageContext.pushBody();
                                       }

    You should get your keyboard fixed. There's a lot of letters missing from what you type and it makes it very hard for other people to read. It looks extremely inelegant.
    Anyway, your JSP isn't in control of the download. (You shouldn't have all that Java code in a JSP either but that's a separate issue.) All it does is to send the data to the browser, which is in charge of the download. And in all the browsers I use, there's a box which tells you how far the download has proceeded. No real need for a progress bar, even if you could persuade the browser to make one. Which you can't.

  • I want to  download Mavericks on my iMac.  I presently have 10.6.8. Sadly I am a total klux when downloading and need very simple advice please.

    I want to upgrade from O S 10.6.8 but am a total klux when downloading.  Instructions have to be very simple.  Thanks a lot.

    Check to make sure your applications are compatible. PowerPC applications are no longer supported after 10.6.      
    Application Compatibility
    Applications Compatibility (2)

  • Need help with progress bar !!!!!!!

    Is ther anyway to display the progress of functions, which I created in my application, through a progress bar ... while the results are being computed with my alogs..
    They are quite long and it takes quite sometime for the results to generate and user shud see that something is working ... while he waits and shud feel that nothing is happening ....
    The progress shudnt necessarily be measurable ... a non measurable progress bar will also do .... Jst want to show that some activity is goin on at the back ...
    My algo consist of functions :
    for (i = 0 ; i < = 6 ; i++)
    my function 1 (my parameters) {} - called 10 times each time the i increments with different parameters
    my function 2() {} - called 10 times ....
    my functions 3() {}   - called 10 times IF somebody know how to do it ... please help meee......... its urgent

    Are you posting this on your cell phone? There seems to be something horribly wrong with your keyboard or your auto complete for your words, as it is, I could barely understand what you were asking. If that is the way you actually spell, then I doubt anyone could help you, maybe you should just step away from the keyboard or what ever device it is your are using to input, because it's correct operation seems to escape you--will you actually be able to comprehend a solution if it is presented?
    But on the outside chance that you may be a savant, and just cannot form sentences and words properly, here is an idea...
    Ages ago, long before you were ever an itch in your parents'... you get the picture...
    They used to say: "Hey, I'm going to be doing a lot of processing or repetitive tasks and maybe between each task I should do something to let the user know the process is running and not just locked up."
    Even a status bar needs you to do something between each process, you have to make it do something between executions of tasks.

  • [SOLVED] Almost there just need a global progress bar

    Heya,
    There's no man page for bar so I have looked at the code a bit. I am trying to have a progress bar to copy a folder with many files including symbolic links (unfortunately pycp does not support them yet). With the -s parameter, I can specify the approximate size of what I am copying but it works only if it is a single file.
    I have also tried pv, pipemeter, orphan advcp, ecp, scp and I am now desperate.
    Would someone be kind enough to help me ?
    [tamikana@archlinux ~]$ cat /usr/bin/bar
    #! /bin/sh
    # bar
    # 'cat' with ASCII progress bar
    # (c) Henrik Theiling
    BAR_VERSION=1.4
    # Synopsis:
    # 'bar' works just like 'cat', but shows a progress bar in ASCII art on stderr.
    # The script's main function is meant to be usable in any Bourne shell to be
    # suitable for install scripts without the need for any additional tool.
    # Shell Script Usage: bar [options] [files]
    # Options:
    # -h displays help
    # Examples:
    # Normal pipe:
    # : bar mypack.tar.bz2 | tar xjpf -
    # Individual pipe for each file:
    # : bar -c 'tar xjpf -' mypack1.tar.bz2 mypack2.tar.bz2
    # Individual pipe, using ${bar_file} variable:
    # : bar -c 'echo ${bar_file}: ; gzip -dc | tar tvf -' \
    # : -e .tar.gz \
    # : file1 file2 file3 file4 file5 \
    # : > package-list.txt
    # Programs and shell commands:
    # Required (otherwise this fails):
    # if, then, else, fi, expr, test, cat, eval, exec
    # shell functions
    # test:
    # a = b
    # a -lt b
    # a -gt b
    # a -le b
    # -f a
    # -n a
    # -z a
    # expr:
    # a + b
    # a - b
    # a '*' b
    # a / b
    # a : b
    # Optional (otherwise this does not show the bar):
    # grep, dd, echo, ls, sed, cut
    # ls:
    # must output the file size at fifth position.
    # The command line interface also uses:
    # awk
    ####>-SCHNIPP-<########################################################
    bar_cat()
    # Use this shell function in your own install scripts.
    # Options:
    # Width of the bar (in ten characters). The default is 76 characters.
    test -z "${BAR_WIDTH}" && test -n "${COLUMNS}" && BAR_WIDTH=${COLUMNS}
    # Check syntax:
    ( expr "${BAR_WIDTH}" + 0 >/dev/null 2>&1 ) || BAR_WIDTH=0
    BAR_WIDTH=`expr ${BAR_WIDTH} + 0` || BAR_WIDTH=0
    test "x${BAR_WIDTH}" = x0 && BAR_WIDTH=76
    # Maximal block size to use for dd.
    test -n "${BAR_BS}" || BAR_BS=1048567
    # BEGIN PERC
    # Whether to show a percentage.
    test -n "${BAR_PERC}" || BAR_PERC=1
    # END PERC
    # BEGIN ETA
    # Whether to show estimated time of arrival (ETA).
    test -n "${BAR_ETA}" || BAR_ETA=1
    # END ETA
    # Width of the trace display:
    # BEGIN TRACE
    test -n "${BAR_TRACE_WIDTH}" || BAR_TRACE_WIDTH=10
    # END TRACE
    # The command to execute for every given file. Each file
    # is piped into this command individually. By default, the
    # files are simply dumped to stdout.
    test -n "${BAR_CMD}" || BAR_CMD=cat
    # The characters to be used in the bar
    test -n "${BAR_L}" || BAR_L='['
    test -n "${BAR_R}" || BAR_R=']'
    test -n "${BAR_C0}" || BAR_C0='.'
    test -n "${BAR_C1}" || BAR_C1='='
    # Additional extension to add to each file:
    #BAR_EXT=${BAR_EXT-}
    # Whether to clear bar after termination. Otherwise keep the full bar.
    #BAR_CLEAR=${BAR_CLEAR-0}
    # Unless switched off by user, use the bar by default:
    test -n "${BAR_OK}" || BAR_OK=1
    BAR_WIDTH=`expr ${BAR_WIDTH} - 3`
    bar_trace=''
    # BEGIN TRACE
    if test "x${BAR_TRACE}" = x1
    then
    BAR_WIDTH=`expr ${BAR_WIDTH} - ${BAR_TRACE_WIDTH}`
    bar_lauf=${BAR_TRACE_WIDTH}
    bar_t_space=''
    bar_t_dot=''
    while test "${bar_lauf}" -gt 1
    do
    bar_t_space="${bar_t_space} "
    bar_t_dot="${bar_t_dot}."
    bar_lauf=`expr ${bar_lauf} - 1`
    done
    bar_trace="${bar_t_space} "
    fi
    # END TRACE
    bar_eta=''
    BAR_GET_TIME='echo'
    # BEGIN ETA
    ( expr 1 + ${SECONDS} >/dev/null 2>&1 ) || BAR_ETA=0
    if test "x${BAR_ETA}" = x1
    then
    BAR_GET_TIME='( echo ${SECONDS} )'
    BAR_WIDTH=`expr ${BAR_WIDTH} - 6`
    bar_eta='--:-- '
    fi
    # END ETA
    bar_perc=''
    # BEGIN PERC
    if test "x${BAR_PERC}" = x1
    then
    BAR_WIDTH=`expr ${BAR_WIDTH} - 5`
    bar_perc=' 0% '
    fi
    # END PERC
    BAR_GET_SIZE='( ls -l "${BAR_DIR}${bar_file}${BAR_EXT}" | sed "s@ *@ @g" | cut -d " " -f 5 ) 2>/dev/null'
    # portable?
    # check features:
    ( ( echo a ) >/dev/null 2>&1 ) || BAR_OK=0
    ( ( echo a | dd bs=2 count=2 ) >/dev/null 2>&1 ) || BAR_OK=0
    ( ( echo a | grep a ) >/dev/null 2>&1 ) || BAR_OK=0
    ( ( echo a | sed 's@ *@ @g' ) >/dev/null 2>&1 ) || BAR_OK=0
    ( ( echo a | cut -d ' ' -f 1 ) >/dev/null 2>&1 ) || BAR_OK=0
    # check ranges:
    test "${BAR_WIDTH}" -ge 4 || BAR_OK=0
    BAR_ECHO='echo'
    BAR_E_C1=''
    BAR_E_C2=''
    BAR_E_NL='echo'
    # Does echo accept -n without signalling an error?
    if echo -n abc >/dev/null 2>&1
    then
    BAR_E_C1='-n'
    fi
    # Check how to print a line without newline:
    if ( ( ${BAR_ECHO} "${BAR_E_C1}" abc ; echo 1,2,3 ) | grep n ) >/dev/null 2>&1
    then
    # Try echo \c:
    if ( ( ${BAR_ECHO} 'xyz\c' ; echo 1,2,3 ) | grep c ) >/dev/null 2>&1
    then
    # Try printf:
    if ( ( printf 'ab%s' c ; echo 1,2,3 ) | grep abc ) >/dev/null 2>&1
    then
    BAR_ECHO='printf'
    BAR_E_C1='%s'
    else
    BAR_ECHO=':'
    BAR_E_C1=''
    BAR_E_NL=':'
    BAR_OK=0
    fi
    else
    BAR_E_C1=''
    BAR_E_C2='\c'
    fi
    fi
    # prepare initial bar:
    bar_shown=0
    if test "${BAR_OK}" = 1
    then
    bar_lauf=0
    bar_graph=''
    while test `expr ${bar_lauf} + 5` -le "${BAR_WIDTH}"
    do
    bar_graph="${bar_graph}${BAR_C0}${BAR_C0}${BAR_C0}${BAR_C0}${BAR_C0}"
    bar_lauf=`expr ${bar_lauf} + 5`
    done
    while test "${bar_lauf}" -lt "${BAR_WIDTH}"
    do
    bar_graph="${bar_graph}${BAR_C0}"
    bar_lauf=`expr ${bar_lauf} + 1`
    done
    ${BAR_E_C2}" 1>&2_eta}${bar_perc}${BAR_L}${bar_graph}${BAR_R}
    bar_shown=1
    fi
    # for shifting large numbers so that expr can handle them:
    # Assume we can compute up to 2147483647, thus 9 arbitrary digits.
    # We must be able to do + of two numbers of 9 digits length. Ok.
    # BEGIN LARGE
    ( ( test 1999999998 = `expr 999999999 + 999999999` ) >/dev/null 2>&1 ) || BAR_OK=0
    bar_large_num="........."
    bar_div=""
    # END LARGE
    bar_numsuff=""
    # find size:
    bar_size=0
    if test -n "${BAR_SIZE}"
    then
    bar_size=${BAR_SIZE}
    # BEGIN LARGE
    while expr "${bar_size}" : "${bar_large_num}" >/dev/null 2>&1
    do
    bar_div="${bar_div}."
    bar_numsuff="${bar_numsuff}0"
    bar_size=`expr "${bar_size}" : '\(.*\).$'`
    done
    # END LARGE
    BAR_GET_SIZE="echo '${BAR_SIZE}'"
    else
    for bar_file
    do
    bar_size1=0
    if test -f "${BAR_DIR}${bar_file}${BAR_EXT}"
    then
    bar_size1=`eval "${BAR_GET_SIZE}"`
    # BEGIN LARGE
    # divide and upround by pattern matching:
    if test -n "${bar_div}"
    then
    bar_size1=`expr "${bar_size1}" : '\(.*\)'${bar_div}'$'` || bar_size1=0
    fi
    # adjust if still too large:
    while expr "${bar_size1}" : "${bar_large_num}" >/dev/null 2>&1
    do
    bar_div="${bar_div}."
    bar_numsuff="${bar_numsuff}0"
    bar_size1=`expr "${bar_size1}" : '\(.*\).$'`
    bar_size=`expr "${bar_size}" : '\(.*\).$'` || bar_size=0
    done
    # upround if necessary:
    if test -n "${bar_div}"
    then
    bar_size1=`expr "${bar_size1}" + 1`
    fi
    # END LARGE
    # add to total size:
    bar_size=`expr ${bar_size} + ${bar_size1}`
    # BEGIN LARGE
    # adjust if still too large:
    while expr "${bar_size}" : "${bar_large_num}" >/dev/null 2>&1
    do
    bar_div="${bar_div}."
    bar_numsuff="${bar_numsuff}0"
    bar_size=`expr "${bar_size}" : '\(.*\).$'`
    done
    # END LARGE
    else
    BAR_OK=0
    fi
    done
    fi
    bar_quad=`expr ${BAR_WIDTH} '*' ${BAR_WIDTH}`
    test "${bar_size}" -gt "${bar_quad}" || BAR_OK=0
    if test "${BAR_OK}" = 0
    then
    # For some reason, we cannot display the bar. Thus plain operation:
    for bar_file
    do
    if test "${bar_file}" = "/dev/stdin"
    then
    eval "${BAR_CMD}"
    else
    eval "${BAR_CMD}" < "${BAR_DIR}${bar_file}${BAR_EXT}"
    fi
    done
    else
    # Compute wanted bytes per step:
    bar_want_bps=`expr ${bar_size} + ${BAR_WIDTH}`
    bar_want_bps=`expr ${bar_want_bps} - 1`
    bar_want_bps=`expr ${bar_want_bps} / ${BAR_WIDTH}`
    # Compute block count per step to keep within maximum block size:
    bar_count=1
    if test "${bar_want_bps}" -gt "${BAR_BS}"
    then
    bar_count=`expr ${bar_want_bps} + ${BAR_BS}`
    bar_count=`expr ${bar_count} - 1`
    bar_count=`expr ${bar_count} / ${BAR_BS}`
    fi
    # Compute block size for given count:
    bar_wc=`expr ${BAR_WIDTH} '*' ${bar_count}`
    bar_bs=`expr ${bar_size} + ${bar_wc}`
    bar_bs=`expr ${bar_bs} - 1`
    bar_bs=`expr ${bar_bs} / ${bar_wc}`
    # Compute bs * count, the bytes per step:
    bar_bps=`expr ${bar_bs} '*' ${bar_count}`
    # Compute bytes per hundredth:
    bar_bph=`expr ${bar_size} + 99`
    bar_bph=`expr ${bar_bph} / 100`
    # Run loop:
    bar_pos=0
    bar_graph="${BAR_L}"
    bar_cur_char=0
    bar_t0=`eval "${BAR_GET_TIME}" 2>/dev/null` || bar_t0=0
    for bar_file
    do
    # BEGIN TRACE
    if test "x${BAR_TRACE}" = x1
    then
    bar_trace=`expr "${bar_file}" : '.*/\([^/][^/]*\)$'` || bar_trace="${bar_file}"
    bar_trace=`expr "${bar_trace}${bar_t_space}" : '\('${bar_t_dot}'\)'`
    bar_trace="${bar_trace} "
    fi
    # END TRACE
    # Initial character position in bar for file:
    bar_char=`expr ${bar_pos} / ${bar_want_bps}` || bar_char=0
    while test "${bar_char}" -gt `expr ${bar_cur_char} + 4`
    do
    bar_graph="${bar_graph}${BAR_C1}${BAR_C1}${BAR_C1}${BAR_C1}${BAR_C1}"
    bar_cur_char=`expr ${bar_cur_char} + 5`
    done
    while test "${bar_char}" -gt "${bar_cur_char}"
    do
    bar_graph="${bar_graph}${BAR_C1}"
    bar_cur_char=`expr ${bar_cur_char} + 1`
    done
    # Get file size. This must work now (we checked with test -f before).
    bar_size1=`eval "${BAR_GET_SIZE}" 2>/dev/null` || bar_size1=0
    # BEGIN LARGE
    # Divide and upround by pattern matching:
    if test -n "${bar_div}"
    then
    bar_size1=`expr "${bar_size1}" : '\(.*\)'${bar_div}'$'` || bar_size1=0
    bar_size1=`expr "${bar_size1}" + 1`
    fi
    # END LARGE
    # loop:
    bar_total=0
    exec 6>&1
    exec 5<"${BAR_DIR}${bar_file}${BAR_EXT}"
    while test "${bar_total}" -lt "${bar_size1}"
    do
    dd bs="${bar_bs}" count="${bar_count}${bar_numsuff}" <&5 >&6 2>/dev/null
    bar_total=`expr ${bar_total} + ${bar_bps}`
    if test "${bar_total}" -gt "${bar_size1}"
    then
    bar_total="${bar_size1}"
    fi
    bar_pos1=`expr ${bar_pos} + ${bar_total}`
    bar_proz=`expr ${bar_pos1} / ${bar_bph}` || bar_proz=0
    # BEGIN PERC
    if test "x${BAR_PERC}" = x1
    then
    bar_perc=" ${bar_proz}% "
    bar_perc=`expr "${bar_perc}" : '.*\(.....\)$'`
    fi
    # END PERC
    # BEGIN ETA
    if test "x${BAR_ETA}" = x1
    then
    bar_diff=`eval "${BAR_GET_TIME}" 2>/dev/null` || bar_diff=0
    bar_diff=`expr ${bar_diff} - ${bar_t0} 2>/dev/null` || bar_diff=0
    bar_100p=`expr 100 - ${bar_proz}` || bar_100p=0
    bar_diff=`expr ${bar_diff} '*' ${bar_100p}` || bar_diff=0
    bar_diff=`expr ${bar_diff} + ${bar_proz}` || bar_diff=0
    bar_diff=`expr ${bar_diff} - 1` || bar_diff=0
    bar_diff=`expr ${bar_diff} / ${bar_proz} 2>/dev/null` || bar_diff=0
    if test "${bar_diff}" -gt 0
    then
    bar_t_unit=":"
    if test "${bar_diff}" -gt 2700
    then
    bar_t_uni="h"
    bar_diff=`expr ${bar_diff} / 60`
    fi
    bar_diff_h=`expr ${bar_diff} / 60` || bar_diff_h=0
    if test "${bar_diff_h}" -gt 99
    then
    bar_eta=" ${bar_diff_h}${bar_t_unit} "
    else
    bar_diff_hi=`expr ${bar_diff_h} '*' 60` || bar_diff_hi=0
    bar_diff=`expr ${bar_diff} - ${bar_diff_hi}` || bar_diff=0
    bar_diff=`expr "00${bar_diff}" : '.*\(..\)$'`
    bar_eta=" ${bar_diff_h}${bar_t_unit}${bar_diff} "
    fi
    bar_eta=`expr "${bar_eta}" : '.*\(......\)$'`
    fi
    fi
    # END ETA
    bar_char=`expr ${bar_pos1} / ${bar_want_bps}` || bar_char=0
    while test "${bar_char}" -gt "${bar_cur_char}"
    do
    bar_graph="${bar_graph}${BAR_C1}"
    ${bar_trace}${bar_eta}${bar_perc}${bar_graph}${BAR_E_C2}" 1>&2
    bar_cur_char=`expr ${bar_cur_char} + 1`
    done
    done
    ) | eval "${BAR_CMD}"
    bar_pos=`expr ${bar_pos} + ${bar_size1}`
    done
    # ${BAR_ECHO} "${BAR_E_C1}" "${BAR_R}${BAR_E_C2}" 1>&2
    fi
    if test "${bar_shown}" = 1
    then
    # BEGIN TRACE
    test "x${BAR_TRACE}" = x1 && bar_trace="${bar_t_space} "
    # END TRACE
    # BEGIN ETA
    test "x${BAR_ETA}" = x1 && bar_eta=' '
    # END ETA
    if test "x${BAR_CLEAR}" = x1
    then
    # BEGIN PERC
    test "x${BAR_PERC}" = x1 && bar_perc=' '
    # END PERC
    bar_lauf=0
    bar_graph=''
    while test `expr ${bar_lauf} + 5` -le "${BAR_WIDTH}"
    do
    bar_graph="${bar_graph} "
    bar_lauf=`expr ${bar_lauf} + 5`
    done
    while test "${bar_lauf}" -lt "${BAR_WIDTH}"
    do
    bar_graph="${bar_graph} "
    bar_lauf=`expr ${bar_lauf} + 1`
    done
    ${BAR_E_C2}" 1>&2_eta}${bar_perc} ${bar_graph}
    else
    # BEGIN PERC
    test "x${BAR_PERC}" = x1 && bar_perc='100% '
    # END PERC
    bar_lauf=0
    bar_graph=''
    while test `expr ${bar_lauf} + 5` -le "${BAR_WIDTH}"
    do
    bar_graph="${bar_graph}${BAR_C1}${BAR_C1}${BAR_C1}${BAR_C1}${BAR_C1}"
    bar_lauf=`expr ${bar_lauf} + 5`
    done
    while test "${bar_lauf}" -lt "${BAR_WIDTH}"
    do
    bar_graph="${bar_graph}${BAR_C1}"
    bar_lauf=`expr ${bar_lauf} + 1`
    done
    ${bar_trace}${bar_eta}${bar_perc}${BAR_L}${bar_graph}${BAR_R}${BAR_E_C2}" 1>&2
    ${BAR_E_NL} 1>&2
    fi
    fi
    ####>-SCHNAPP-<########################################################
    BAR_AWK_0=''
    # Command line interface:
    while test -n "$1"
    do
    case "$1" in
    -o|-c|-w|-0|-1|-e|-d|-b|-s|-\[\]|-\[|-\]|-T)
    if test -z "$2"
    then
    echo "$0: Error: A non-empty argument was expected after $1" 1>&2
    fi
    BAR_ARG="$1"
    BAR_OPT="$2"
    shift
    shift
    -o*|-c*|-w*|-0*|-1*|-e*|-d*|-b*|-T*)
    BAR_ARG=`expr "$1" : '\(-.\)'`
    BAR_OPT=`expr "$1" : '-.\(.*\)$'`
    shift
    -h|-n|-p|-D|-D-|-q|-V|-t|-E|-L)
    BAR_ARG="$1"
    BAR_OPT=""
    shift
    --) shift
    break
    -*) echo "$0: Error: Unrecognized option: $1" 1>&2
    exit 1
    break
    esac
    case "${BAR_ARG}" in
    -h) echo 'Usage: bar [-n] [-p] [-q] [-o FILE] [-c CMD] [-s SIZE] [-b SIZE]'
    echo ' [-w WIDTH] [-0/1/[/] CHAR] [-d DIR] [-e EXT] [Files]'
    echo ' bar -V'
    echo ' bar -D'
    echo ' bar -D-'
    echo 'Options:'
    echo ' -h displays help'
    echo ' -o FILE sets output file'
    echo ' -c CMD sets individual execution command'
    echo ' -e EXT append an extension to each file'
    echo ' -d DIR prepend this prefix to each file (a directory must end in /)'
    echo ' -s SIZE expected number of bytes. Use for pipes. This is a hint'
    echo ' only that must be greater or equal to the amount actually'
    echo ' processed. Further, this only works for single files.'
    echo ' -b SIZE maximal block size (bytes) (default: 1048567)'
    echo ' -w WIDTH width in characters (default: terminal width-3 or 76)'
    echo ' -0 CHAR character for empty bar (default: .)'
    echo ' -1 CHAR character for full bar (default: =)'
    echo ' -[ CHAR first character of bar (default: [)'
    echo ' -] CHAR last character of bar (default: ])'
    echo ' -n clears bar after termination'
    echo ' -t traces (=displays) which file is processed'
    echo ' -T WIDTH no of characters reserved for the file display of -t'
    echo ' -p hides percentage'
    echo ' -E hides estimated time display'
    echo ' -q hides the whole bar, be quiet'
    echo ' -D tries to dump the bar_cat() shell function, then exit.'
    echo ' Here, -t, -p, -E remove the corresponding feature completely.'
    echo ' Further, -L removes large file support from the code.'
    echo ' -D- same as -D, but dumps the function body only'
    echo ' -V displays version number'
    echo ' -- end of options: only file names follow'
    exit 0
    -n) BAR_CLEAR=1
    -L) BAR_LARGE=0
    BAR_AWK_0="${BAR_AWK_0} /END *LARGE/ {x=1} ;"
    BAR_AWK_0="${BAR_AWK_0} /BEGIN *LARGE/ {x=0} ;"
    -t) BAR_TRACE=1
    BAR_AWK_0="${BAR_AWK_0} /END *TRACE/ {x=1} ;"
    BAR_AWK_0="${BAR_AWK_0} /BEGIN *TRACE/ {x=0} ;"
    -T) BAR_TRACE_WIDTH="${BAR_OPT}"
    -q) BAR_OK=0
    -p) BAR_PERC=0
    BAR_AWK_0="${BAR_AWK_0} /END *PERC/ {x=1} ;"
    BAR_AWK_0="${BAR_AWK_0} /BEGIN *PERC/ {x=0} ;"
    -E) BAR_ETA=0
    BAR_AWK_0="${BAR_AWK_0} /END *ETA/ {x=1} ;"
    BAR_AWK_0="${BAR_AWK_0} /BEGIN *ETA/ {x=0} ;"
    -V) echo "bar v${BAR_VERSION}"
    exit 0
    -D) echo "BAR_VERSION=${BAR_VERSION}"
    awk "${BAR_AWK_0}"'{sub(/ *#.*$/,"")} ; /^bar_cat/ {x=1} ; {sub(/^ */,"")} ; /./ {if(x)print} ; /^}/ {x=0}' "$0"
    exit 0
    -D-) echo "BAR_VERSION=${BAR_VERSION}"
    awk "${BAR_AWK_0}"'{sub(/ *#.*$/,"")} ; /^}/ {x=0} ; {sub(/^ */,"")} ; /./ {if(x)print} ; /^{/ {x=1}' "$0"
    exit 0
    -o) exec 1>"${BAR_OPT}"
    -c) BAR_CMD="${BAR_OPT}"
    -b) BAR_BS="${BAR_OPT}"
    if BAR_RAW=`expr "${BAR_BS}" : '\(.*\)k$'`
    then
    BAR_BS=`expr ${BAR_RAW} '*' 1024`
    elif BAR_RAW=`expr "${BAR_BS}" : '\(.*\)M$'`
    then
    BAR_BS=`expr ${BAR_RAW} '*' 1048567`
    fi
    -s) BAR_SIZE="${BAR_OPT}"
    if BAR_RAW=`expr "${BAR_SIZE}" : '\(.*\)k$'`
    then
    BAR_SIZE=`expr ${BAR_RAW} '*' 1024`
    elif BAR_RAW=`expr "${BAR_SIZE}" : '\(.*\)M$'`
    then
    BAR_SIZE=`expr ${BAR_RAW} '*' 1048567`
    fi
    if test "$#" -gt 1
    then
    echo "Error: -s cannot be specified for multiple input files." 1>&2
    exit 1
    fi
    -e) BAR_EXT="${BAR_OPT}"
    -d) BAR_DIR="${BAR_OPT}"
    -0) BAR_C0="${BAR_OPT}"
    -1) BAR_C1="${BAR_OPT}"
    -\[) BAR_L="${BAR_OPT}"
    -\]) BAR_R="${BAR_OPT}"
    BAR_L="${BAR_OPT}"
    BAR_R="${BAR_OPT}"
    -w) BAR_WIDTH="${BAR_OPT}"
    esac
    done
    # Invoke main function:
    if test "$#" = 0
    then
    bar_cat /dev/stdin
    else
    bar_cat "$@"
    fi
    EDIT: solved https://bbs.archlinux.org/viewtopic.php … 85#p498885
    It seems like I have not tried every potential packages after all
    Last edited by tamikana (2011-10-30 16:04:46)

    This might help http://www.dwcourse.com/dreamweaver/ten-commandments-spry-menubars.php#one
    Also, if you use DW CS5 click on Live Code and Live View. Then when clicking on the menu items in Live View, watch the changes in classes that occur. This mifgt give you a clue of what to do.
    Cheers,
    Gramps

  • Please help my email boxes have gone .i am not very technical so need very simple words.

    Please help my email boxes have gone .i am not very technical I am the older generation.

    Lyndaneedshelp wrote:
    Thank you for replying . I do not have the all mailboxes in the left hand side of the email page. I cannot go to any of my mailboxes . I am receiving  mail  but the can put them in the boxes but cannot go into the boxes. Hope I am making sense. I am not very technical older generation. Thank you
    OK. Sounds like you are simply below the top level of the Inbox menu. Look at the upper left of the mail box list. You should some text (what exactly will depend on where you are) precedded by an <. Tap on that until you return to the top of the list.
    Also - Phil could very well be correct (hard to say with being able to see your screen).

  • Progress Bar Widget

    Hi.
    I'm looking for a simple progress bar (a.k.a ticker) widget and wondering if anyone knows of one that might exist.
    Everything I see is for a specific purpose - none that match my need.
    I am looking for something more universal, where I can set the starting value, goal value and then manually change the current value and the meter displays the 'progress' with a solid bar on a scale.
    A common assimilation would be to the "thermometer" a charity may use to illustration how much money they've raised relative to what the ultimate goal is.
    The Nike widget is the closest visually to what I am looking for - but of course it has a very specific application. I need something that will let me set my own unit of measure - be it weight or currency or whatever.
    There are tickers that you can build on the internet for using on a website. Does anyone know if something like this exists for the Dashboard?
    Thx.

    I'm not sure I understand what you mean.
    Take a countdown widget by example.
    It assumes starting date is TODAY.
    I can assign an ending date.
    It calculates how many days are left and displays that.
    For a progress bar, I would imagine this would be even more simple.
    For example, I want to track progress of a fund raising.
    There is a field where I specify starting amount = 0
    A field where I specify what the goal amount is = 100
    A field to specify unit value being measured (weight, currency or days - for example)
    And a field where I enter the "current amount" - for example 25.
    The widget simply displays a solid bar within the scale proportionate to the amount I've entered as the current value.
    This requires code - I understand that. But I don't see why this can't be done - and am quite surprise that I haven't been able to find an existing widget that already does this. I'm not really wanting to learn the API for creating my own widget if I can help it.

  • How can i use Progress bar in IR Report

    Hi ,
    I have created IR Report based on the View so, it's been taking 10-15 mins of time to execute the IR Report. Here user want to see the Progress bar while executing the IR Report. How can i use Progress bar in IR Report.
    Anybody have idea on Progress bar please help me.
    Regards
    Narender B

    Hi ,
    Thanks for your information.
    I am new to the APEX.*i need to show Progress bar while opening the each page* then user can know some process is happening from the backside and i don't know where i need to add and call the below function.could you please provide the steps for the progress bar.
    In my application there are almost 100 pages are there so, i need to show progress bar on each page while opening .could you please provide Global function to call on each page.
    function html_url_Progress(pThis){ 
    $x_Show('AjaxLoading');
    window.setTimeout('$s("AjaxLoading",$x("AjaxLoading").innerHTML)', 100);
    //doSubmit('APPLY_CHANGES');
    redirect(pUrl);
    Regards
    Narender B

  • Progress bar to update as script runs

    Hi, I'd like to have a progress bar being displayed as my script runs. I created a simple progress bar as follows:
    var win = new Window("palette", "SnpCreateProgressBar", [150, 150, 600, 260]);
    win.pnl = win.add("panel", [10, 10, 440, 100], "Script Progress");
    win.pnl.progBar = win.pnl.add("progressbar", [20, 35, 410, 60], 0, 100);
    win.pnl.progBarLabel = win.pnl.add("statictext", [20, 20, 320, 35], "0%");
    win.show();
                        while(win.pnl.progBar.value < win.pnl.progBar.maxvalue)
                                  // this is what causes the progress bar increase its progress
                                  win.pnl.progBar.value++;
                win.pnl.progBarLabel.text = win.pnl.progBar.value+"%";
                                  $.sleep(10);
        alert('Done!');
    win.close();
    Now, if I target the ExtendScript Toolkit, I can see the "animation" of the bar progressing. But If I target illustrator, I only see when it's at 0% and then it jump to 100%. Is there a way to update the information visually as the script progresses?
    Thanks!
    I'm running CS6 on mac.

    Hi,
    i was using the above code in my application but it is displaying the following message when i run it:
    Can you please help me out.
    Thanks
    Harsh    

  • Progress Bar doesnt show

    why doesnt progress bar show on ie/ns?....Thank you all.
    <cfif isdefined('form.Process') and form.process eq "Process" and isdefined('Form.rosterfile') and form.rosterfile neq "">
    <cfset CurrDir = GetDirectoryFromPath(GetTemplatePath())>
      <cfset StorageDir = GetDirectoryFromPath(GetTemplatePath()) & "Storage\">
          <div id="display_while_running">
             <table align="center" border="0" cellpadding="0" cellspacing="0" style="border:solid 1px green; background : #backgroundcolor1#; width:600px;padding:5px; text-align:center;">
              <tr>
                <td >
                  <b>Please wait while it is processing...</b>
                </td>
              </tr>
              <tr>
                <td>
                 <img src="../imgs/progressbar2.gif" width="250" height="20">
                </td>
              </tr>
            </table>
          </div>
        <!---CFOUTPUT>#RepeatString(" ",300)#</CFOUTPUT--->
          <!---cfflush--->
          <cffile action="upload"
          destination="#StorageDir#"
          nameConflict="overwrite"
          fileField="Form.rosterfile">
          <cfset strFilePath ="#StorageDir##cffile.serverFile#">
          <cfset strFile ="#cffile.serverFile#">
          <cfquery datasource="#application.Orc#" name="GetFileName">  
            Select FILE_NAME from ops$rms.HR_File
            where
            lower(file_name) = lower('#strFile#')
         </cfquery>
        <cfif GetFileName.recordcount neq 0>
          <cfset msg = "This file has been already uploaded. Please upload a different one.">
        <cfelse>
            <cfflush interval="10">
            <cfset CurrFilePath ="#CurrDir##cffile.serverFile#">
            <cffile action = "copy" source="#strFilePath#" destination="#CurrDir#">
            <cffile action="rename" source="#CurrFilePath#" destination="#CurrDir#HrXls.xls">
            <cflock name="xlsloader" timeout="300" type="exclusive">
                  <cfset command = "java RMSHRFileReader C:\Inetpub\wwwroot\RMS\hr_loader\HrXls.xls">
                  <cfset syscmd = createObject("java","au.com.webcode.util.SystemCommand").init()>
                  <cfset result = syscmd.execute(command,"300000")> <!---5 mins, must be a string--->
                  <cfif result.getExitValue() neq 0>
                   <cfset msg = "The uploading process has been partially completed.">
           </cfif>
            </cflock>
            <cfquery datasource="#application.Orc#" name="InsFileName">
              insert into ops$rms.HR_File(file_name, updated_on, updated_by)
              values('#strFile#',SYSDATE,'#session.username#')
            </cfquery>
            <cfset stdout = 1> 
            <cffile action = "delete" file="#CurrDir#HrXls.xls">
        </cfif>
      <script language="Javascript">
          document.getElementById('display_while_running').style.display='none';
        </script>
    </cfif>

    Because ColdFusion code starts executing after the contents of the
    file to be uploaded is received by the server. In other words when
    you're trying to show the progress bar there's no need for a progress
    bar because the upload is at 100%.
    Mack

  • Progress Bar is not working in Labview 6i

    Hi all,
    i implemented one vi with  Progress bar using labiview 6i. i created property node for the progress bar to set the range as 550 using scale >Range>maximum. progress bar is updating well until the value of 220. later the progress bar is starting from begining. What is the maximum range we can define for the Progress bar.? please see the attached picture . Am i missing anything from the figure?
    thanks,
    kalpana 
    Attachments:
    Progress Bar.png ‏60 KB

    Hi kalpu,
    as your "slide" is of datatype U8 it will not display values greater than 255…
    Best regards,
    GerdW
    CLAD, using 2009SP1 + LV2011SP1 + LV2014SP1 on WinXP+Win7+cRIO
    Kudos are welcome

  • PROGRESS BAR IN FORMS6I

    HI.. FRIENDS
    HOW TO USE PROGRESS BAR IN FORMS6I
    PLEASE GIVE ME SAMPLE CODE
    REGARDS
    SANTOSH RANE

    Hi,
    I am in search of a progress bar solution for Forms6i. Do you still have a copy of your solution? Kindly email it to me at: [email protected]
    Thanks in advance!

  • Progress bar according to databases status?

    Helo frens........
    i need to display progress bar according to database status i.e. as one programm is taking data (mobile no ) and sending msg to that mobile no how to display it

    Helo frens........
    i need to display progress bar according to database
    status i.e. as one programm is taking data (mobile no
    ) and sending msg to that mobile no how to display itI don't know of a way to estimate how much of your query job is done, nor do I know of a database tool that is sufficiently accurate to allow a percentabe type of update progress to be shown, but you could make a moving bar that resets when it hits the end--make it fairly rapidly moving to not confuse anyone looking at it--so they don't think it is an actual one time through and your are done progress type.
    The progress bar needs to run in a seperate thread then and when your process returns from it's call, then you shut down your progress bar.

  • Would someoen show me example of progress bar?

    i am confused by Sun's explanation... i just wanna make a simple progress bar thats sorta like a timer.... you get a number, say 100, and the progress bar will show the progress of a thread counting to that number in seconds...

    ugly Q&D,
    import java.awt.*;
    import javax.swing.*;
    public class ProgressBar
          private static JFrame f = null;
          public PPanel p = null;
          private int min = 0;
          private int max = 100;
          private int now = 0;
          private int count = -1;
          private long sleepTime = 500;
          private Thread clockThread = null;
          private volatile boolean noStopRequested = true;
          private Runnable r = null;
          private class PPanel extends JPanel
             public void repaint()
                Graphics g = getGraphics();
                if( null == g ) return;
                g.setColor( Color.cyan );
                double d = ( (double) now / (double) max ) * getWidth();
                g.fillRect( 0, 0, (int) d, getHeight() );
          public ProgressBar()
          public void setNow( int i )
          this.now = i;
          p.repaint();
          private void initialize()
          p = new PPanel();
          p.setPreferredSize( new Dimension( 100, 10 ) );
          try
             r = new Runnable()
                   public void run()
                   try
                      runWork();
                   catch( Exception e )
                      e.printStackTrace();
                      //error
          catch( Exception  e )
             e.printStackTrace();
          clockThread = new Thread( r );
          clockThread.start();
          public static void main( String[] args )
          ProgressBar pg = new ProgressBar();
          pg.initialize();
          f = new JFrame();
          JPanel pp = (JPanel) f.getContentPane();
          pp.add( pg.p );//bad
          f.pack();
          f.show();
          private void runWork() {
          while( noStopRequested ) {
             try {
                this.process();
                Thread.sleep( sleepTime );
             } catch( Exception e ) {
                //error
                e.printStackTrace();
          private void process()
          setNow( count++ );
          if( count == max )
             f.dispose();
          public void stopRequest()
          noStopRequested = false;
          clockThread.interrupt();
          public void startRequest()
          noStopRequested = true;
          clockThread.interrupt();
    }

Maybe you are looking for