Link to home
Start Free TrialLog in
Avatar of Seven price
Seven priceFlag for United States of America

asked on

image button programatic in a table

I have a programatic table in vb, I want to have and image button that reads a folder.
What will happen is when the same is found in the database and matches the same name in the folder the image will show up.

I just need the correct synatx.
How can I match the images in my folder with the image name in the database to show up in my table.

  Dim mypath = Server.MapPath("image/imagefolder")
           
            Do While sqlDR.Read
                r = New TableRow ' << place here start new row
                c = New TableCell ' << place here start new table cell
                cnt = cnt + 1

                img = New ImageButton
                img.Width = "80"
                img.Attributes.Add("onclick", "")
                img.ID = "myNewimage" + cnt.ToString()
                c.Controls.Add(img)
                r.Cells.Add(c)
ASKER CERTIFIED SOLUTION
Avatar of AndyAinscow
AndyAinscow
Flag of Switzerland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Seven price

ASKER

adulll to me. Just could not think straight, thanks.