Having a JTextArea scroll when output is written to it

I'm using a JTextArea (inside a JScrollPane) as a console, and I use the append() method to update the text area with various information. I'd like the JTextArea to automatically scroll down as more lines get added onto it, similar to a shell or command prompt.
It seems "autoscroll" refers to something else, and the scrollpane horizontal/vertical policy refers to the display, not behavior, of the scrollpane. Can anyone point me in the right direction?
Message was edited by:
k1cheng

i've done this in the past by adding
textArea.setCaretPosition(
textArea.getDocument().getLength());
after the append. hope this helps!This works great. Thanks.
camickr, you are right. Thanks.

Similar Messages

  • How to find 'OS user' used by Oracle Reports when report output is written

    Hi ,
    I would like to find the 'OS User' used by concurrent manager when a Report output is written on the OS file system after the report run is completed. The report is registered as a concurrent program in Oracle Application environment.
    Any help would be appreciated.Pls respond urgently.
    Thanks
    Sudeep

    There is only one OS user that creates reports out and log files, that is applSID, the owner of the applications filesystems. The only other OS user that creates files in an Oracle Applications environment is oracle (or oraSID) if a stored procedure creates a file via utl_file_dir, or external table etc.

  • How to re-arrange columns when outputting a SELECT statement?

    Assume a table holds a lot of columns: A, B, C, D, E,......., Z
    When outputting the result auf a SELECT statement the columns should be re-arranged as follows:
    The first column should be E, then the second column should be C and then all remaining columns should
    follows in a order as if there would be no re-ordering. How can I do this in SQL WITHOUT having to list all
    columns individually like in:
    SELECT E,C, A, B,D,F,.....,Z FROM .....
    Furthermore the first and second column should not re-appear again (twice) as in a statement like
    SELECT E, C, * FROM .....;
    How can I achieve this?
    Peter

    Hi,
    Welcom to the forum!
    Posting your own question in someone else's thread is called "hijacking".
    More people will read (and answer) your question if you start your own thread.
    You can include a link to this thread, if you think that will help people. See the "Plain Text Help" on the right side of the "Edit Message" screen to learn how.
    If you have more output than will fit on one line, then you can
    (1) Increase the size of the line, or
    (2) Decrease the size of the output
    or both.
    Display issues like this always depend on your front-end.
    For example, in SQL*Plus you can use SET LINESIZE to make lines bigger, and COLUMN to reduce wasted space within the lines.
    When you start your own thread, be sure to mention your front-end tool and version.

  • Hi! I'm just having a little trouble when it comes to battery charging of my iPhone 5 with its new iOS 7! It doesn't indicates that the battery is fully charge unlike the old version of iOS! They said it should be pulsating but it's not

    Hi! I'm just having a little trouble when it comes to battery charging of my iPhone 5 with its new iOS 7! It doesn't indicates that the battery is fully charge unlike the old version of iOS! I already read some reviews and discussion about this. They said that the lightning bolt should pulsate when charging but it's not!

    Thanks for the replies. It took a while not hearing anything so thought I was alone. I have done many of the suggestions already. The key here is that it occurs on both phones with apps, and phones still packaged in a box.
    A Genius Bar supervisor also checked his Verizon data usage log and found the same 6 hour incremental use. Suprisingly, he did not express much intrigue over that. Maybe he did, but did not show it.
    I think the 6 hour incremental usage is the main issue here. I spoke with Verizon (again) and they confirmed that all they do is log exactly when the phone connected to the tower and used data. The time it records is when the usage started. I also found out that the time recorded is GMT.
    What is using data, unsolicited, every 6 hours?
    Why does it change?
    Why does it only happen on the iPhone 5 series and not the 4?
    Since no one from Apple seems to be chiming in on this, and I have not received the promised calls from Apple tech support that the Genius Bar staff said I was suppose to receive, it is starting to feel like something is being swept under the rug.
    I woke up the other day with another thought ... What application would use such large amounts of data? Well ... music, video, sound and pictures of course. Well ... what would someone set automatically that is of any use to them? hmmm ... video, pictures, sound. Is the iPhone 5 succeptible to snooping? Can an app be buried in the IOS that automatically turns on video and sound recording, and send it somewhere ... every 6 hours? Chilling. I noted that the smallest data usage is during the night when nothing is going on, then it peaks during the day. The Genius Bar tech and I looked at each other when I drew this sine wave graph on the log print outs during an appointment ...

  • I am having a problem. When I click on the Mobile Facebook icon it acts like it is going to start opening then it quits and goes back to the icon. So I can't use Facebook on my iPhone 4

    I am having a problem. When I click on the Mobile Facebook icon it acts like it is going to start opening then it quits and goes back to the icon. So I can't use Facebook on my iPhone 4

    Force quit the application and try again.
    Try a reset or restart of the device, trying the app after each step.

  • Every time I create a button it moves to the centre of the page when outputing to pdf

    every time I create a button it moves to the centre of the page when outputting to pdf
    I have done a load of tests and it does it every time
    I imported a jpg image as my button. Converted it to a button by Interactive/convert button. Even before I setup all the options in the buttons panel it moves. So for instance I have the button in the bottom RHS in Indesign. Then make a interactive pdf and its in the centre of the page. I have even converted the image back to an object and it goes back to in proper position.
    I have tried this in several documents, starting from scratch and using different images and also drawn a button. I have also used the buttons from the button library
    In previous version of Indesign I have never uncounted this problem.
    2 weeks later to above post
    Can anyone help this has not be resolved and I have several annual reports to get out urgently. Its happening to all documents!

    every time I create a button it moves to the centre of the page when outputting to pdf
    I have done a load of tests and it does it every time
    I imported a jpg image as my button. Converted it to a button by Interactive/convert button. Even before I setup all the options in the buttons panel it moves. So for instance I have the button in the bottom RHS in Indesign. Then make a interactive pdf and its in the centre of the page. I have even converted the image back to an object and it goes back to in proper position.
    I have tried this in several documents, starting from scratch and using different images and also drawn a button. I have also used the buttons from the button library
    In previous version of Indesign I have never uncounted this problem.
    2 weeks later to above post
    Can anyone help this has not be resolved and I have several annual reports to get out urgently. Its happening to all documents!

  • Having a constant error when downloading latest update for Illustrator CC, error message: Adobe Illustrator CC Latest Updates (December 2014) Installation failed. Error Code: U44M1P7

    Having a constant error when downloading latest update for Illustrator CC, error message:
    Adobe Illustrator CC Latest Updates (December 2014) Installation failed. Error Code: U44M1P7

    U44.. update error http://forums.adobe.com/thread/1289956 may help
    -more U44.. discussion http://forums.adobe.com/thread/1275963
    -http://helpx.adobe.com/creative-suite/kb/error-u44m1p7-installing-updates-ccm.html
    -http://helpx.adobe.com/creative-suite/kb/error-u44m1i210-installing-updates-ccm.html

  • I am having autocad not respond when I am making a pdf using autocad 2002 and adobe acrobat XI

    I am having autocad not respond when I am making a pdf using autocad 2002 and adobe acrobat XI
    We have adobe acrobat 8 on another system that seems to work fine,  what elsedo we need to do to get this trial version to work properly.
    We are able to get everything set up , sized, etc,  but when the actual process starts it is stating  "autocad not responding and it  just spins and never makes the actual final pdf.
    Any help on this would be appreciated

    It's probably a compatibility problem with the updated PDF libraries vs. you hopelessly old ACAD that can't be resolved. In any case, I'd consider it one of those things of trying to attack the problem on the wrong end. All major CAD programs have native PDF export these days and even ACAD has had since v2006 at least...
    Mylenium

  • I just paid for Adobe PDF pack and I think I am having problems installing. When I select to print from word, PDF is not an option. Help!

    I just paid for Adobe PDF pack and I think I am having problems installing. When I select to print from word, PDF is not an option. Help!

    Hi voltric2014,
    If you are on Windows, you can download and install the CreatePDF Desktop Printer, which would allow you to "print" to PDF from Word. You'll find a link to the installer on the CreatePDF page at https://cloud.acrobat.com. Here are the instructions for installing it: Using Adobe PDF Pack
    Please let us know if you have additional questions.
    Best,
    Sara

  • PSE 7 Crashes when outputing to any format - Help!

    I have used the program (PSE 7) on the same machine for the past 2 years with limited issues - have always been able to restart the workstation and program and get my slide show outputed to the desired format.  I am expereincing the same issue again this year, but no matter how many time I restart the program crashes at random times when outputing.  May crash right away or at any different percentage of completion during the output process.
    Do I reinstall on the same machine?  If so, will I be able to recover all fo the work I have done?
    Do I upgrade to the newer version?  Will I have the same issue? 
         Shoudl I try to down load the trial version first?  Not sure if it over writes the current version and if I would lose anything?
    Please Help!  Needs some guidance as I have to get the annual High School Softball video completed by Monday for the banquet.

    Do I reinstall on the same machine?  If so, will I be able to recover all fo the work I have done?
    Uninstalling and reinstalling will not affect your existing catalog, nor saved slideshow projects. If you also use Premiere Elements note that PRE video projects no longer appear in the organizer, although they can still be opened directly in PRE.
    Do I upgrade to the newer version?  Will I have the same issue? 
    Without an identified cause of the existing problem that question cannot be answered.
    Shoudl I try to down load the trial version first?  Not sure if it over writes the current version and if I would lose anything?
    Yes, install the trial. Multiple version of PSE can coexist. When installing a later version of PSE I always make a copy of the catalog from my previous version and convert that rather than the original.
    Cheers,
    Neale
    Insanity is hereditary, you get it from your children

  • Class names not sticking when output as book?

    Indesign CC, outputting to ePUB from a book file with 4 chapters, does not output the correct, named class in the CSS and source code, the class takes the name of the style instead.
    As a check, I output a single chapter using File > export and my named classes were retained in both source code and CSS sheet.
    Bug?

    Answering my own post 
    I was contacted by one of the Adobe team responsible for epub output and he put me right on this issue.
    In Book files, there is the concept of a Style Source - that .indd file contains all of the styles for the book and is used to copy all of the styles to the other chaters in the book. When outputting to an ePUB (and, I guess, a PDF file) form the Book file, then the styles in that .indd file are used across the project.
    In my testing, I had shortened the class names for each of the styles in the constituent chapters except in the source file, so the original class names were being used for each of the HTML files being output to the ePUB. Once the source file had been updated, then the output worked as expected.

  • When is anything written to standby redo logs on standby database?

    I am on Oracle 10.2.0.4 on HP UNIX. I have read Oracle 10.2 concepts guide on technet.oracle.com, have read may article on metalink and internet, yet I am unable to verify when anything is written to standby redo logs on stand by database.
    I have a simple database reconfiguration: a primary database and one standby database.
    I created primary database and set up log_archive_dest_2 to use LGWR SYNC AFFIRM
    I have created standby redo logs on primary.
    alter database add standby logfile GROUP
    I create standby control file on primary.
    I copied all the primary information to create standby database. I have put standby database in managed recovery.
    I did archive log switches, I created a table and inserted information in table.
    I never saw standby redo logs updated on standby database by looking at timestamp of standby redo log files.
    I then setup database in maximum availability mode by running following on primary:
    Alter database set standby database to maximize availability
    When I do insert into my tables, I do see standby redo log files on primary database being updated, but I have never seen standby redo logs on standby database updated. Why?
    I am still at loss when actually standby redo logs are updated on standby database.
    When I read Oracle 9i database documentation on data guard, it says that you do not need standby redo logs on primary instead you need them on standby. Only reason, you need them on primary is from primary changes role to standby database, so standby redo logs on standby database should be updated instead of standby redo logs on primary.

    What is the PROTECTION_MODE ,PROTECTION_LEVEL values of your database.
    As per metalink:--
    Create standby redo log files, if necessary:
    Standby redo logs are necessary for the higher protection levels such as
    Guaranteed, Instant, and Rapid. In these protection modes LGWR from the
    Primary host writes transactions directly to the standby redo logs.
    This enables no data loss solutions and reduces the amount of data loss
    in the event of failure. Standby redo logs are not necessary if you are using
    the delayed protection mode.
    If you configure standby redo on the standby then you should also configure
    standby redo logs on the primary database. Even though the standby redo logs
    are not used when the database is running in the primary role, configuring
    the standby redo logs on the primary database is recommended in preparation
    for an eventual switchover operation.
    Standby redo logs must be archived before the data can be applied to the
    standby database. The standby archival operation occurs automatically, even if
    the standby database is not in ARCHIVELOG mode. However, the archiver process
    must be started on the standby database. Note that the use of the archiver
    process (ARCn) is a requirement for selection of a standby redo log.
    METALINK ID:- Doc ID: Note:219344.1
    Edited by: Anand... on Sep 15, 2008 2:15 AM

  • Today I was charged INR 60 for downloading "FREE APP" of Kotak Mahindra Bank. There is no mention of this charge of INR 60 anywhere. Pls therefore reverse this charge immediately. When it's written FREE it should not be charged.

    Today I was charged INR 60 for downloading "FREE APP" of Kotak Mahindra Bank. There is no mention of this charge of INR 60 anywhere. Pls therefore reverse this charge immediately. When it's written FREE it should not be charged.

    you are just talking to other users like you.  You need to contact the developer.

  • Standalone Projector won't work on a Mac when output from Mac Flash 8 Pro

    Standalone Projector won't work on a Mac when output from Mac Flash 8 Pro
    I'm outputting a Mac projector file that will work on my mac computer. However, when I upload it to FTP and download it my mac or another mac, it won't work! What's going on? I've tried adding ".app" to my file and it still won't work. Help!
    Here's my set up: Flash 8 Pro on Mac Intel with Mac OS 10.4.11

    Hi,
    Does it work if you .zip up the projector and FTP the .zip and then unzip the projector on the other Mac's?  A projector is basically an application.  Applications in Mac's have package contents and resource bundles.  When copying files over the network on Mac's, symbolic links inside the package contents and bundles can get messed up.
    Thanks,
    Nivesh

  • I just downloaded Acrobat and it won't work. Why won't it work? I keep having it quit unexpectedly when I try to launch it.

    I just downloaded Acrobat and it won't work. Why won't it work? I keep having it quit unexpectedly when I try to launch it. I've tried uninstalling and reinstalling. I've tried restarting my computer.  Any suggestions? I fit all they system requirements.

    Hi again CueBallMcDraw,
    What operating system are you on? If your issue isn't related to your subscription being in a pending state (as I discussed in your other post), we'll look closer at what's going on with your system. But, I suspect you're going to be fine once your order finishes processing.
    Please let us know how it goes.
    Best,
    Sara

Maybe you are looking for

  • I have an iPhone 5 16gb white color and i did not get any of the services from apple pls help[ me out

    I have one iphone 5 16 gb white colour with me and its in still under warranty and my phone was fallen down by chance and it got turned off totally and not even switched on also then i went to apple authorised service center for regarding the same .

  • Change FILE to IDOC by HTTP to IDOC scenario

    Hi !!! We have a txt FILE to IDOC scenario. Now we want to implement a HTTP  to IDOC scenario, but taking advantage of the mappings existing and avoid re-implement it. The HTTP calls must contain the text of the actual FILE. What is the best way to d

  • How to make "MXKollection + ADDT" work with php 5.3+

    Hello Everyone, I am back again to this forum after i suffered a lot while trying to use my old website created with "MXKollection" and "ADDT" tools, i have faced a lot of deprecated functions along with the "Registration" + "Login" + "Send Email". E

  • Photoshop layer problems when cloning multiple folders

    I have a leayer with a bit map inside a photosop folder in my layers. When I clone it the layer information  just disapears. When I ctrl+alt to duplicate it sometimes the layers are active but there is no artwork at all Layer is visible /eye is on/ w

  • Unable to add POP Account for Outlook 2011 for Mac.

    Hi, I have bought the Outlook 2011 for Mac recently, but I am unable to add an account for my email Here is what I did: Tools > Accounts> (a window pops out) > click "Email Account" and the thing just froze. Tried restarting and reinstalling.. but do