Jump to content
Software FX Community



Recommended Posts

We are currently upgrading our 6.2 charts to 7.0.  We have a business object that returns chrt.GetHtmlTag.  According to the migration guide, we should be able to call Literal1.Text = chart1.RenderControl();


<?xml:namespace prefix = v ns = "urn:schemas-microsoft-com:vml" /><?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />GetHtmlTag

Chart RenderControl

Literal1.Text = chart1.RenderControl();



 The problem is that RenderControl() returns void.  So I

Link to comment
Share on other sites

RenderControl renders directly to the response object.

If you were doing:



You will now do:


 If you were doing something else with the returned value, then you have a few options:

Original code:

string s = chart,.GetHtmlTag();

New code:

StringWriter sw = new StringWriter();HtmlTextWriter html = new HtmlTextWriter(sw);


string s = sw.ToString();

Or you can use RenderToStream to obtain more detailed information.

Link to comment
Share on other sites

I was able to build the app with your suggestions but I get a broken image now in the application. My app is trying to display: https://localhost/chartfx70/pss/ChartFX.aspx?id=0-073113160&type=png&mime=image%2fpng

 A file does get generated in the Temp file in c:\...\...\ChartFX7.0\PSS\Temp but I can't display that if I navigate to it directly either.

The relevant code in 6.2 was:charts.Add(chart.GetHtmlTag(chartWidth, chartHeight,"image"));

In 7.0 is now: chart.RenderControl(htmlWriter);charts.Add(sw.ToString());


The html tag that is produced is: "<map id=\"Map\" name=\"Map\">\r\n</map>\r\n<img id=\"\" src=\"/chartfx70/pss/ChartFX.aspx?id=0-073112570&type=png&mime=image%2fpng\"  WIDTH=\"375\" HEIGHT=\"250\"  usemap=\"#Map\" border=\"0\"/>" object {string}

it used to be: "<IMG SRC=\"/chartfx62/temp/CFT0731_011000349B0.png\"  WIDTH=\"848\" HEIGHT=\"300\" >" object {string}



<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />



Link to comment
Share on other sites

The Image Tag looks OK, the reference to PSS is correct. PSS is a new feature in Chart FX 7.0

> A file does get generated in the Temp file in c:\...\...\ChartFX7.0\PSS\Temp but I can't display that if I navigate to it directly either.

In your IIS Manager you should have a an application named "Chartfx70" pointing to <chart fx install folder>\chartfx70, inside it there should be a PSS Application.

Another thing I see is that your chart doesn't seem to have an Id. Make sure you assign an ID to your chart as this is now necessary.



Link to comment
Share on other sites

I assigned the ID although it didn't solve my issue. I do have the ChrtFX70 app in IIS with a PSS app inside.  I was trying to figure out if there is something I need to look for to see if the PSS service is working correctly.  I was reading all of the documentation about the PSS service and I am wondering about the following;

There are also of settings in ChartFX.WebForms.config that affect the interaction between Chart FX and PSS, these settings are controlled independently for each web application. ChartFX.WebForms.config has to be included in the bin folder of your web application.


It doesn't indicate where to find the chartfx.webforms.config file to place in the bin of my app...do I have to create this config file?  There is no chartfx.webforms.config file in the bin of my app.

Link to comment
Share on other sites

1) You don't need chartfx.webforms.config. This can be created only if you want to change some default behavior. More info here:

Q7621004. The Chart FX PSS Service in a nutshellURL: http://support.softwarefx.com/ShowArticleSep.aspx?Type=KB&Product=CfxNet70&Source=http://support.softwarefx.com/kb/762/1/004.htm?_r=1

2) You failed to confirm whether or not you are running 7.0.2664.

3) Using IIS:

> I copied the dlls from c:\program files\chart fx for visual studio 2005\bin to c:\inetpub\wwwroot\myapp\bin

> c:\program files\chart fx for visual studio 2005\chartfx70\download to c:\inetpub\wwwroot\myapp\chartfx70\download

You don't want to do this. You need to make sure the appropriate IIS virtual folders are created.

4) Issue with ASP.NET web server

Check the source of the page being generated. What's the Url for the <OBJECT> tag?

Link to comment
Share on other sites

  • 1 year later...


This topic is now archived and is closed to further replies.

  • Create New...