Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.java.gui > #1576

Updating a Single Progres

From "Jason Cavett" <jason.cavett@THRWHITE.remove-dii-this>
Subject Updating a Single Progres
Message-ID <1178309830.795758.96030@h2g2000hsg.googlegroups.com> (permalink)
Newsgroups comp.lang.java.gui
Date 2011-04-27 15:34 +0000
Organization TDS.net

Show all headers | View raw


  To: comp.lang.java.gui
Hello,

I'm trying to update a single JProgressBar that is contained within a
cell of a JTable in order to show the progress that has been completed
on analyzing some data.  The JTable shows items that have already been
processed, the current item processing (there can only be one) and
items waiting to be processed.

>From the looks of things, I need to create my own TableModel (which I
did - it extends DefaultTableModel), I need to create my own
TableCellRenderer (which I did - it impelements TableCellRenderer AND
extends JProgressBar) and I need to add the renderer to the specific
column that will hold the JProgressBar.

So far, so good.  Everything works.

The problem I have is that I don't have an apparent way to update the
value of the JProgressBar.  For example, when a run finishes, the
JProgressBar should stay at 100.  Then, the next item should be
processed going form 0 - 100.  The progress of processing is
determined via another class (which is Observable).  I am trying to
figure out how to update just the JProgressBar in question.

Sorry if this post rambles a bit.  I am lost here.  If anybody can
give me some insight, I'd appreciate it.  I've been reading forums,
etc which is how I got to where I'm at now, but the whole updating
process doesn't seem to work as I thought it would.


Thanks for any clarification.

---
 * Synchronet * The Whitehouse BBS --- whitehouse.hulds.com --- check it out free usenet!
--- Synchronet 3.15a-Win32 NewsLink 1.92
Time Warp of the Future BBS - telnet://time.synchro.net:24

Back to comp.lang.java.gui | Previous | NextNext in thread | Find similar | Unroll thread


Thread

Updating a Single Progres "Jason Cavett" <jason.cavett@THRWHITE.remove-dii-this> - 2011-04-27 15:34 +0000
  Re: Updating a Single Pro "Lionel van den Berg" <lionel.van.den.berg@THRWHITE.remove-dii-this> - 2011-04-27 15:34 +0000
    Re: Updating a Single Pro "Jason Cavett" <jason.cavett@THRWHITE.remove-dii-this> - 2011-04-27 15:34 +0000
      Re: Updating a Single Pro "Michael Rauscher" <michael.rauscher@THRWHITE.remove-dii-this> - 2011-04-27 15:34 +0000

csiph-web