M
Mango
Hi there, I will be very happy if someone helps me. I need to create dynamic
image, and save the state between the postback. I mean I've got 5 buttons
and when I click on one of them, the image is creted with:
System.Web.UI.WebControls.Image Img1 = new
System.Web.UI.WebControls.Image();
Img1.ImageUrl = newPath;
Panel1.Controls.Add(Img1);
That's work fine but when I click on some of the other buttons I lost the
Image.
I tried this:
System.Web.UI.WebControls.Image Img1 = new
System.Web.UI.WebControls.Image();
Panel1.Controls.Add(Img1);
Img1.ImageUrl = newPath;
But it does not help me. I cant use OnInit, so the only way which I know is
to add image in design time and do it with Panel1.visible=false ,but I am
looking for more intelligent way to do it.
Any idea?
image, and save the state between the postback. I mean I've got 5 buttons
and when I click on one of them, the image is creted with:
System.Web.UI.WebControls.Image Img1 = new
System.Web.UI.WebControls.Image();
Img1.ImageUrl = newPath;
Panel1.Controls.Add(Img1);
That's work fine but when I click on some of the other buttons I lost the
Image.
I tried this:
System.Web.UI.WebControls.Image Img1 = new
System.Web.UI.WebControls.Image();
Panel1.Controls.Add(Img1);
Img1.ImageUrl = newPath;
But it does not help me. I cant use OnInit, so the only way which I know is
to add image in design time and do it with Panel1.visible=false ,but I am
looking for more intelligent way to do it.
Any idea?