aspose file tools
The moose likes XML and Related Technologies and the fly likes Problem with Transformer throwing NullPointer while Reading xsl file Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Engineering » XML and Related Technologies
Reply Bookmark "Problem with Transformer throwing NullPointer while Reading xsl file" Watch "Problem with Transformer throwing NullPointer while Reading xsl file" New topic
Author

Problem with Transformer throwing NullPointer while Reading xsl file

Amee Dabo
Ranch Hand

Joined: Dec 22, 2001
Posts: 74
Hi,

tran = (TransformerFactory.newInstance().newTransformer(new StreamSource(xsltPath)));

Above line of code is giving Null Pointer exception at run time:The exception is :
java.lang.NullPointerException
at com.utility.XSLTransformer.doSomeTransform(XSLTransformer.java:84)

xsltPath is a String & set to E:\Tomcat\webapps\mypeppod\xsl\treeMenu.xsl
treeMenu.xsl resides at the path metioned above
I have the same code for all files on my local machine taken from production erver.This code works perfectly well on production server -- doesnt give Nullpointer but on local machine this doesnt work & throws NullPointer.

Any idea where I might be going wrong?

I am completely new to xml..Please help..

Thanks,
Ameeta

[ August 04, 2006: Message edited by: Amee Dabo ]
[ August 04, 2006: Message edited by: Amee Dabo ]

Thanks..
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 56185
    
  13

You couldn't come up with a better subject?

Please read this and this.
[ August 04, 2006: Message edited by: Bear Bibeault ]

[Smart Questions] [JSP FAQ] [Books by Bear] [Bear's FrontMan] [About Bear]
Amee Dabo
Ranch Hand

Joined: Dec 22, 2001
Posts: 74
I am new to xml/xslt & was struggling for 3 all days & nights on the problem but didnt get through & so made me write the subject line like this.Apologies for the same.Will take care in future.

Regards,
Ameeta
 
I agree. Here's the link: http://zeroturnaround.com/jrebel - it saves me about five hours per week
 
subject: Problem with Transformer throwing NullPointer while Reading xsl file
 
Similar Threads
V2Solutions,Mumbai
7yrs-Total , 3.5yrs-Java/J2EE- Looking out for job in Mumbai
Which one to choose: project based or product based
syntel
here are my findings