Author: amitguitarplayer | Posted on: 7/31/2008 3:33:17 PM | Views : 290

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 ...