Skip to main content
Inspiring
December 18, 2008
Answered

Coldfusion.setGlobalError handler Issue

  • December 18, 2008
  • 1 reply
  • 435 views
I am Currently using Cfdiv to load the contents and there after i am using the cfchart in the

same cfdiv using Ajaxlink to load the cfchart and show statistical dta in flash format. Well it

works somewhat on chrome/firefox but not in other browsers. I searched a lot and found that there

is no workaroud to fix this yet?..

One solution i found that use jpg and then decode it using binary to show data but that seems

extra trival task.

So i found 1 solution to use the coldfusion.setglobalerrorHandler.

in my graph.cfm

i am using the function as:
<cfajaximport>
<script>
ColdFusion.setGlobalErrorHandler(function(error){
if(typeof console != "undefined"){
console.log(error);
} else {
alert(error);
}
});
</script>
i added this script inn the file called graph.cfm
but it does not seem to work...

is something wrong i am doing..

This topic has been closed for replies.
Correct answer thenotorious_flag
Thanks Azadi

1 reply

Inspiring
December 18, 2008
add it to your main page that displays grap.cfm in cfdiv.
and shorthand for cfajaximport is <cfajaximport/>.
and it should be n your main page, too, if you need it at all...

and i find it no extra hassle to do
<cfchart type="png" name="mychart" ...>
<cfchartseries ...>
</cfchart>
at the top of a page, and then later in code use
<cfimage action="writetobrowser" source="#mychart#">
to display the chart image.
works a treat all the time...


Azadi Saryev
Sabai-dee.com
http://www.sabai-dee.com/
thenotorious_flagAuthorCorrect answer
Inspiring
December 18, 2008
Thanks Azadi