Thanks everyone for your replies.

Unfortunetly I am still doing something wrong.

I get this error when I run the code:
500 org/apache/batik/dom/svg/ExtensibleSVGDOMImplementation
org/apache/batik/dom/svg/ExtensibleSVGDOMImplementation 

Which is also what I get when I <CFDUMP> MakeImage,  Which I thought should
show the methods?

If I understood this page:
http://livedocs.adobe.com/coldfusion/7/htmldocs/wwhelp/wwhimpl/common/html/w
whelp.htm?context=ColdFusion_Documentation&file=00001566.htm

Note: The cfdump tag displays an object's public methods and data.



So maybe I did not do the CLASS PATH corrrectly in CF admin?

I entered:
E:\batik\batik-1.7\batik.jar
E:\batik\batik-1.7\batik-rasterizer.jar
....

Or should I go the next level down and map:
E:\batik\batik-1.7\lib (+\file.jar)



And
WOW you guys work late.

Thanks
Rodney

-----Original Message-----
From: Janet MacKay [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, May 08, 2007 10:32 PM
To: CF-Talk
Subject: Re: Using .jar file with <cfobject>


> <cfset svgPath = "e:\temp\newxml.svg" />
> <cfset svgFile = expandPath(svgPath) /> 

Rodney,

Don't use expandPath() if you're going to supply an absolute path. That
might have been what was messing you up.  


This worked for me

<!--- svg file is in same directory as script ---->
<cfobject action="create" type="java"
class="org.apache.batik.transcoder.image.PNGTranscoder" name="MakeImage"> 
<cfset svgFile = ExpandPath("newxml2.svg") /> 
<cfset pngFile = ExpandPath("newxml2.png") /> 
<cfset svgURI =
createObject("java","java.io.File").init(svgFile).toURL().toString() /> 
<cfset input =
createObject("java","org.apache.batik.transcoder.TranscoderInput").init(svgU
RI) /> 
<cfset ostream =
createObject("java","java.io.FileOutputStream").init(pngFile) /> 
<cfset output =
createObject("java","org.apache.batik.transcoder.TranscoderOutput").init(ost
ream) /> 
<cfset MakeImage.transcode(input, output) /> 
<cfset ostream.flush() />
<cfset ostream.close() /> 

<cfoutput>
<embed src="#svgFile#" width="1024" height="265" type="image/svg+xml" />
<img src="#pngFile#" /> </cfoutput> 






~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
ColdFusion MX7 by AdobeĀ®
Dyncamically transform webcontent into Adobe PDF with new ColdFusion MX7. 
Free Trial. http://www.adobe.com/products/coldfusion?sdid=RVJV

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:277550
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

Reply via email to