You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-user@logging.apache.org by Michael Roytman <MR...@Novarra.com> on 2001/05/29 17:38:44 UTC

RE: How to log into JTextArea, File and NTEventLog simultaneously ?

Aleksey,

you can use org.apache.log4j.gui.TextPaneAppender
if you need to log to a JTextArea.
You need to create your own JTextPane, wrap it in a scrollable pane,
then create textPaneAppender and pass your JtextPane to your
textPaneAppender in setTextPane method and you're done.

Michael

> -----Original Message-----
> From: Aleksey Nikolayev [mailto:admiralspb@yahoo.com]
> Sent: Sunday, May 27, 2001 8:51 PM
> To: log4j-user@jakarta.apache.org
> Subject: How to log into JTextArea, File and NTEventLog 
> simultaneously?
> 
> 
> Hello Everyone,
> 
> Just failed to find out any clues on how to log into
> JTextArea? Couldn't find any example in the 'examples'
> section. (essential code snippet would be of great
> help, if you can, pls)
> 
> And another question I have - How to log into
> JTextArea, File and NTEventLog simultaneously? (or
> just anywhere simultaneously) (more general answer
> and/or code snippet desirable, since I do not get the
> idea completely - is it in examples somewhere?) 
> 
> Thanks a lot. 
> 
> 
> 
> 
> =====
> Aleksey Nikolayev
> admiralspb@yahoo.com
> 
> __________________________________________________
> Do You Yahoo!?
> Yahoo! Auctions - buy the things you want at great prices
> http://auctions.yahoo.com/
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: log4j-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: log4j-user-help@jakarta.apache.org
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: log4j-user-help@jakarta.apache.org