I am trying to make a custom user control to load images
private string _imageFolderPath;
public string ImageFolderPath
{
get { return _imageFolderPath; }
set { _imageFolderPath = value; }
}
void Page_Load()
{
string imageToDisplay = GetRandomImage();
imgRnd.ImageUrl = Path.Combine(_imageFolderPath, imageToDisplay);
lblImage.Text = imageToDisplay;
}
private string GetRandomImage()
{
Random rnd = new Random();
strin ...
Go to the complete details ...