I have an image control on an asp page that is not behaving correctly. When I specify a size by pixel, it shows as that size, however, if I specify as a percentage, there's no error, the page displays (all other info) but the image itself does not show. I can view source, copy and paste the image tag on a completely different page and it will show when that page is viewed. I'm wanting to specify by percentage because the original jpg's are huge and need to fit within the browser window without having to scroll around. Any ideas why using as percentage will not work?
This code works:
Dim img As New WebControls.Image
img.ImageUrl = "Prints/" + Request.QueryString("PrintName")
img.Height = Unit.Pixel(50)
img.Width = Unit.Pixel(50)
Me.PlaceHolder1.Controls.Add(img)
this code does not work:
Dim img As New WebControls.Image
img.ImageUrl = "Prints/" + Request.QueryString("PrintName")
img.Height = Unit.Percentage(50)
img.Width = Unit.Percentage(50)
Me.PlaceHolder1.Controls.Add(img)
thanks for any info!
-xeno
This code works:
Dim img As New WebControls.Image
img.ImageUrl = "Prints/" + Request.QueryString("PrintName")
img.Height = Unit.Pixel(50)
img.Width = Unit.Pixel(50)
Me.PlaceHolder1.Controls.Add(img)
this code does not work:
Dim img As New WebControls.Image
img.ImageUrl = "Prints/" + Request.QueryString("PrintName")
img.Height = Unit.Percentage(50)
img.Width = Unit.Percentage(50)
Me.PlaceHolder1.Controls.Add(img)
thanks for any info!
-xeno