asp.net C# variable as Image1.ImageUrl property
- by ModS
I would like to Click "buttonImage1" and have that store "photos/Image1.jpg"
into a var called Photo. then have ButtonImage2.ImageUrl = (Photo).
I am using an UpdatePanel to refresh the area with the images so the only problem is actually setting the variable correctly and then using it correctly.
Reworded: how can I store a path to an image in a variable then set it correctly as a image's URL path?
protected void Button2_Click(object sender, ImageClickEventArgs e)
{
Evt = ("~/events/ev2.jpg");
}
protected void Image2_Click(object sender, ImageClickEventArgs e)
{
Image1.ImageUrl = (Evt);
}