Saving hidden charts
Posted: Thu May 26, 2005 5:34 am
When the user saves a chart to a metafile, we want the chart form to be maximized, otherwise the image scale is bad.
To avoid flicker, we save the state of the form, then:
Visible = false;
WindowState = wsMaximized;
Chart1->SaveToMetafileEnh(filename);
then restore the form to user's size and make visible
Howeve, the chart is not maximized when hidden. We can get this work if we maximize without hiding the chart, but we don't want the flicker of maximizing and restoring the chart while it's visible.
We also need the generic ability to create and save charts (as metafiles) that are not displayed on the screen.
Help?
Kevin
To avoid flicker, we save the state of the form, then:
Visible = false;
WindowState = wsMaximized;
Chart1->SaveToMetafileEnh(filename);
then restore the form to user's size and make visible
Howeve, the chart is not maximized when hidden. We can get this work if we maximize without hiding the chart, but we don't want the flicker of maximizing and restoring the chart while it's visible.
We also need the generic ability to create and save charts (as metafiles) that are not displayed on the screen.
Help?
Kevin