Thursday, February 4, 2010

To show users photo, take users Image url from db. then assign image path of disk to ImageUrl.

string ImageUrlFromDB = dt.Rows[0]["ImageUrl"].ToString();
string UserImage = Session["rootPath"] + "/UserImages/" + ImageUrlFromDB.ToString().Trim();
Image1.ImageUrl = UserImage;
Image1.AlternateText = "img";

No comments:

Post a Comment