To show image in full screen

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • ramsham
    New Member
    • Feb 2010
    • 10

    To show image in full screen

    HI every one.

    I had code to create image buttons dynamically to show images from folder in web application using C#.net. I want that if the mouse pointer is over an Image(or on image button Click event) then it should show full image with respect to that image button .
    will it possible?

    Code:
    foreach (string filepath in Directory.GetFiles("D:/WEB/images_Botinfo"))
                {
                    string imagename = new FileInfo(filepath).Name;
                    string imageid = imagename.Split('_')[0].ToString();
                    SqlDataReader plantid = obj_bl_dravya.select_iden_rb_imageID(lstbxsearch.SelectedItem.Text.ToString());
                    if (plantid.HasRows)
                    {
                        plantid.Read();
                        string id = plantid.GetValue(0).ToString();
                        if (imageid == id)
                        {
                            ImageButton imgbtn = new ImageButton();
                            imgbtn.Height = 190;
                            imgbtn.Width = 175;
                            Label lblspace = new Label();//to give space between images
                            lblspace.Height = 20;
                            lblspace.Width = 15;
                            pnlImages.Controls.Add(lblspace);
                            imgbtn.ImageUrl = filepath.ToString();
                            pnlImages.Controls.Add(imgbtn);
                            pnlImages.Visible = true;                                
                        }
                    }                
                }
    Last edited by tlhintoq; Mar 15 '10, 02:36 PM. Reason: [CODE] ...Your code goes between code tags [/CODE]
  • tlhintoq
    Recognized Expert Specialist
    • Mar 2008
    • 3532

    #2
    TIP: When you are writing your question, there is a button on the tool bar that wraps the [code] tags around your copy/pasted code. It helps a bunch. Its the button with a '#' on it. More on tags. They're cool. Check'em out.

    Comment

    Working...