Yes it is indeed working. I am not sure why it didn't work when I was testing. Thanks 
for replying back.Anyway, I have another problem wherenin I need to put the logdir 
value in an xml file and source it into log4j.xml rather than get it from -D 
option.Eg:- I have two files log4j.xml and test.xml file Sample Contents of test.xml 
file are shown below.test.xml ----------Sample Contents of test.xml file are shown 
below.log4j.xml--------        
      
      
           where XXXX should hold the value of logdir tag. Is there anyway we can 
source one xml file into another file.Pls let me know. Thanks again.--- Ceki Gülcü  
wrote:> > "java -Dlogdir=C:/java TestLogger" should work with> DOMConfigurator. What > 
goes wrong?> > At 13:24 30.01.2003 -0800, you wrote:> >Hi,> >> >I am having problem 
writing a xml config file for> >log4j. Like I need to subsitute -D option values> 
into> >xml config file.> >> >Eg: java -Dlogdir=C:/java  TestLogger> >> >Substituting 
the logdir value into log4j.xml as> shown> >below(shown by an arrow).> >> >log4j.xml> 
>---------> >   >class="org.apache.log4j.RollingFileAppender">> >      
> >      
> >      
 >value="${logdir}/log/test/xml_testsamp.log"/>  >  >      
> >      > >   > >> >> >Can somebody pls let me know if DOMConfigurator> >supports 
>substituting values into log4j.xml file> that> >were passed as -D option.> >> >I 
>really don't want to do the substitution based on> >environment values.> >> >> >> >> 
>>__________________________________________________> >Do you Yahoo!?> >Yahoo! Mail 
>Plus - Powerful. Affordable. Sign up> now.> >http://mailplus.yahoo.com> >> 
>>---------------------------------------------------------------------> >To 
>unsubscribe, e-mail:> [EMAIL PROTECTED]> >For additional 
>commands, e-mail:> [EMAIL PROTECTED]> > --> Ceki> > > > 
>---------------------------------------------------------------------> To 
>unsubscribe, e-mail:> [EMAIL PROTECTED]> For additional 
>commands, e-mail:> [EMAIL PROTECTED]> 


---------------------------------
Do you Yahoo!?
Yahoo! Mail Plus - Powerful. Affordable. Sign up now

Reply via email to