Hi,
I am using a number of gauges in a dashboard set up (asp.net 2.0, IGv8.1) and occasionally a gauge will not show up when the page loads. If I refresh the page the gauge then shows. My deployment scenario is as follows:
UltraGauge1.DeploymentScenario.ImageType = GaugeImageType.Png; UltraGauge1.DeploymentScenario.DeleteOldImages = true; UltraGauge1.DeploymentScenario.Mode = ImageDeploymentMode.FileSystem; UltraGauge1.DeploymentScenario.ImageURL = "~/images/SalesForce/Gauges/TargetKpi/Gauge_#CLIENT_#SESSION.#EXT"; UltraGauge1.DeploymentScenario.FilePath = "~/images/SalesForce/Gauges/TargetKpi";
The image url on the initial page load is:
http://localhost:4004/BlueCow/images/SalesForce/Gauges/TargetPax/Gauge_ctl00_cphMaster_tpgNational_UltraGauge1_nfctuj45qfghidy0xik0ds55.png?t=128709199775304415
And then when I refresh the page it is:
http://localhost:4004/BlueCow/images/SalesForce/Gauges/TargetPax/Gauge_ctl00_cphMaster_tpgNational_UltraGauge1_nfctuj45qfghidy0xik0ds55.png?t=128709201323972827
You can see how the timestamp (I'm guessing that's what "t" is) has changed slightly. This behaviour happens both locally, and when my site is deployed on a server. I'd say about 95% of the time the gauge image appears correctly, and the other 5% I need to refresh the page. I don't think an image has ever failed to load for me on refreshing.
Any help on this would be greatly appreciated.
Cheers,
James.
The timestamp is just to prevent the browser from using a cached version of the image file, so I don't think it's relevant to this issue.
Try testing this with the latest available hotfix from our website, as it's possible some related fixes were made since the initial release of 8.1. If that doesn't help, try checking if the image file exists on your server once the page loads with the missing image - that will at least hint at the nature of this problem, whether it's a timing issue or if the image simply isn't generated the first time.
David,
when the image is missing from the page, the image is not created on the server. Once I refresh the page the image file appears on the server (and the web page). I thought I mentioned this in my first post but I must have just thought it and not written it. :-)
I will try the latest hotfix and see how that goes.
James
I am having this problem also. I have NetAdvantage Vol.2 CLR 2.0
I have HotFix #2022 which I think is the latest Hotfix. Is this still a problem?
I still have this problem. But I have not applied any hotfixes. It is intermittent and not a show stopper and there was other work for me to do so I left it as is.
we haven't been able to reproduce this issue in-house, so any information you can provide about your application and your server would help us.
as a workaround, you could try using javascript to evaluate if the gauge image is valid, and call the gauge's CSOM method refresh() if it isn't.
We loaded the latest version and hot fix and still have the problem.
Could you give me an example of how to evaluate if the gauge image is valid and then call refresh?
I will try that and see if it helps.
attach the javascript img.onerror event in the control markup, or in C#:
<igGauge:UltraGauge ID="UltraGauge1" runat="server" onerror="imageError();">
or
this.UltraGauge1.Attributes["onError"] = "imageError();";
here's the javascript imageError function:
function imageError() { ig_getWebControlById("UltraGauge1").refresh() }
Still seems to happen randomly. Calling refresh from Javascript will fix it sometimes, but not all of the time.
We have 4 gauges and a ultrawebgrid, all in an UpdatePanel. I also have an UltraChart on the page. When the grid is clicked, an async postback causes the gauge values to be updated. Two of the gauges are using the same preset and those are the ones that it happens with. I am loading them like this:
oGauge.LoadPreset(System.IO.Path.Combine(Request.PhysicalApplicationPath, "GaugePresets\\GlacierRadialRectangle.xml"), true);
Most of the time it seems to happen when it has been a while since the last click in the grid. Not sure why the other 2 gauges seem to handle that case and this one does not.
One of my other gauges is loading the preset "GaugePresets\\GlacierLinearVerticalThreeBars.xml". The other gauge is built all by code.