Hello again everyone,
I have found another problem when using the imageviewer control:
Pressing the browser refresh button after page load causes a blank image to be inserted into the image viewer or one or more of the images does not render.
Case 2 images in the viewer.
Reresh page.
blank image in viewer, scroll left or right... wala the images show up and the control removes the blank space. What is going on here?
Code
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
If Not IsPostBack Then
Dim dbl_GoalOne As Double
Dim dbl_MileStone As Double
Dim dbl_CurrentSales As Double
Dim str_GoalTitle As String = ""
Dim str_MileStoneTitle As String = ""
ds = get_CurentSalesTotalandGoals()
If Request.Browser.Type.ToString.Contains("Firefox") Then
wiv_Main.StyleSetName = "RubberBlack"
wiv_Main.StyleSetPath = "~/ig_res"
End If
If Not ds.Tables.Count = 0 Then
str_GoalTitle = ds.Tables("TableName").Rows(0).Item("DataField")
If Not ds.Tables("TableName").Rows(0).Item("DataField") Is System.DBNull.Value Then
str_MileStoneTitle = ds.Tables("TableName").Rows(0).Item("DataField")
Else
Hide_MilestoneMarker()
set_CurrentSalesMonthly(dbl_CurrentSales, dbl_GoalOne)
set_CurrentSalesQuarterly(dbl_CurrentSales, dbl_MileStone)
lbl_User_Messages.Visible = True
lbl_User_Messages.Text += " :The data was not retrived from the DataBase."
wiv_Main.Items.Add(New Infragistics.Web.UI.ListControls.ImageItem("~/GaugeImages/GuageQuarterly.png", "SomeText", "SomeText"))
'Else 'This code is not fixing the problem
' wiv_Main.Items.Add(New Infragistics.Web.UI.ListControls.ImageItem("~/GaugeImages/GuageMonthly.png", "Some Text", "Some Text"))
' wiv_Main.Items.Add(New Infragistics.Web.UI.ListControls.ImageItem("~/GaugeImages/GuageQuarterly.png", "Some Text", "Some Text"))
End Sub
Any solutions?
Patrick
Also, when I use the Image Report feature of the tool, the images display correctly in the report.
In IE, i like to use a tool called "IE Developer Toolbar"
http://www.microsoft.com/downloads/details.aspx?familyid=e59c3964-672d-4511-bb3e-2d5e1db91038&displaylang=en
And in Firefox i use a tool called "FireBug"
https://addons.mozilla.org/en-US/firefox/addon/1843
Both of these tools allow you to view the active DOM of a page. And have functionality that allows you to click on any HTML element in the page and view all the information about it.
-SteveZ
SteveZ -
I don't know how to check the URL of the blank image being displayed. It might not even be an image but perhaps just a blank space the size of the other images.
The only references in the source are for the two images that should be displayed along with the images used in the css style applied to the control.
Update:
Looks like there are only two images bound to the control which is correct:
[{'0':[[,,,,"Holman\u0027s Inc. Monthly Goal","~/GaugeImages/GuageMonthly.png","Monthly Goal",,,,,]],
'1':[[,,,,"Holman\u0027s Inc. Quarterly Goal","~/GaugeImages/GuageQuarterly.png","Quarterly Goal",,,,,]]}],[]}, null, null, $get("wiv_Main"));