Search the archives!
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[no subject]
Regards,
Carlo.
"Mishra, Sunil" <Sunil.Mishra@xxxxxx> on 31/08/99 14:52:42
To: Carlo Van de Sompel/ISD/Anhyp/BE, Balaji Srinivasan
<balaji@xxxxxxxxxxx>
cc: advanced-java@xxxxxxxxxxxxxxxx
Subject: RE: Movin ScrollBars from Code
why making easy things so complecated :-) I accept that these are all
general solutions for scrollpanes/scrollbars.
But the easiest solution I found is,
myTextArea.setCaretPosition(myTextArea.getText().length());
Isn't it that easy :-)
Sunil Mishra
Goldman Sachs,
sunilmishra@xxxxxxxxx
201-459-1185(R)
212-346-2602(O)
> -----Original Message-----
> From: cvandeso@xxxxxxxx [SMTP:cvandeso@xxxxxxxx]
> Sent: Tuesday, August 31, 1999 8:28 AM
> To: Balaji Srinivasan
> Cc: advanced-java@xxxxxxxxxxxxxxxx
> Subject: Re: Movin ScrollBars from Code
>
>
>
>
>
> In AWT you can use
> theScrollPane.setScrollPosition( Point aPont ),
> which is a convenience method that allows you to scroll to a certain
> position of the child. (textarea in your case).
>
> Regards,
> Carlo
>
>
>
>
>
> "Balaji Srinivasan" <balaji@xxxxxxxxxxx> on 31/08/99 11:52:28
>
> To: Carlo Van de Sompel/ISD/Anhyp/BE
> cc:
> Subject: Re: Movin ScrollBars from Code
>
>
>
>
> Dear Carlos.
> I have a awt textarea inside an Applet. How can I get the scrollpane
> object
> from the textarea to use your code?
> Thanks
>
> ----- Original Message -----
> From: <cvandeso@xxxxxxxx>
> To: <Balaji_Srinivasan/Development/DFI@xxxxxxxxxxx>
> Cc: <advanced-java@xxxxxxxxxxxxxxxx>
> Sent: Tuesday, August 31, 1999 2:36 PM
> Subject: Re: Movin ScrollBars from Code
>
>
>
>
>
>
>
> Lets say you want to avoid using Rectangle(s) & Bounds & ... (ref.
mailing
> list ( today() - 1) ),
> then you could always try this snipplet :
> final theMaxValue =
theScrollPane.getVerticalScrollBar().getMaximum();
> SwingUtilities.invokeLater(
> new Runnable () {
> public void run () {
> theScrollPane.getVerticalScrollBar().setValue( theMaxValue );
> }
> });
> Regards,
> Carlo
>
>
>
>
> "Balaji Srinivasan" <balaji@xxxxxxxxxxx> on 31/08/99 09:41:01
> To: advanced-java@xxxxxxxxxxxxxxxx
> cc: (bcc: Carlo Van de Sompel/ISD/Anhyp/BE)
> Subject: Re: Movin ScrollBars from Code
>
>
>
> I have a textarea in which I keep on adding data.
> Currently I'm saying something like:
> txtDisp.setText( txtDisp.getText() + "New Text");
> Now the new data added is at the bottom but the focus is at the top..
> How can I bring the scrollbar down?
> ----- Original Message -----
> From: G Ramasubramani <grsmani@xxxxxxxxxxxxxxxx>
> To: <advanced-java@xxxxxxxxxxxxxxxx>
> Sent: Tuesday, August 31, 1999 12:22 PM
> Subject: Movin ScrollBars from Code
>
>
>
> Hi folks,
> Is it possible to move a vertical scrollbar up
> or down by writing code to do it?
> Essentially, I have a JScrollPane and want to
> move the scrollbar from within the code
> whenever particular event is generated.
> Thanks and regards,
> Rama
>
>
>
>
>
>
>
>
>
>
>
- Prev by Date: about URLConnection
- Previous by thread: [no subject]
- Index(es):