I want to put two charts on the other with a z-index in a table cell so that I can make a chart visible On. While refreshing the chart, I want to update the data with the chart under the visual chart, then create the Z-index switch to avoid flicker ... but it does not seem to work and I do not know what I do I am doing this:
This is my CSS
td.tdchart {width: 800px; Status: Relative; Z-index: 100; Display area; }. Charthead {z-index: 200; Status: Completed; Top: 0; Left: 0; Width: 100%; Height: 100%}. ChartWizil {z-index: 300; Status: Completed; Top: 0; Left: 0; Width: 100%; Height: 100%}
Here is a partial ASP page
& lt; Table & gt; & Lt; TR & gt; & Lt; Td square = "tdchart" & gt; & Lt; Div id = "pChart1" runat = "server" class = "chartwise" & gt; & Lt; Asp: chart id = "chart 1" ... & gt; & Lt; / ASP: Chart & gt; & Lt; / Div & gt; & Lt; Div id = "pChart1" runat = "server" class = "chart hidden" & gt; & Lt; Asp: chart id = "chart 1" ... & gt; & Lt; / ASP: Chart & gt; & Lt; / Div & gt; & Lt; / TD & gt; & Lt; / TR & gt; & Lt; / Table & gt;
ASP code in Ajax timer
pChart2.Attributes.Add ("class", "chartisible"); PChart1.Attributes.Add ("Square", "Charted");
This is a long shot because I have not worked on a web form in a while Project and I'm unable to run the web app.
I really think that you do not need 2 identical charts. The code should be repeated to avoid you without any flicker, it is a pain and not efficient for management. Keep your code DRY (do not repeat yourself).
That being said, I think you should remove the second chart and the first chart will be & lt; Asp: UpdatePanel & gt;
.
Potential Fix
I noticed that your UpdatePanel is using conditional settings:
If you have enabled this, you will need to manually trigger your asynchronous postback either by calling UpdatePanel2.Update ()
in your code. Or by setting a trigger, I did not see any of these (but I could forget something).
I recommend that you add it to the bottom of your second timer:
... & Lt; / Trigger & gt; & Lt; / ASP: UpdatePanel & gt;
I believe the update should trigger the timer and update the update panel while updating your chart.
But please note this is an unwanted fix and I absolutely do something like
No comments:
Post a Comment