• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 749
  • Last Modified:

Image Gallery with DataGrid

Hi Experts!
I'm trying to create a little image gallery with the DataGrid. I would like to have 4 column DataGrid with multiple images on the page. I tried creating 4 Template Columns with image Eval("Name","Images/{0}") code expression but I end up with 4 same images per line.
What expression can I use or what can I do to make sure that images in the row do not repeat because right now my DataGrid looks like this:

imageA   |  imageA   |  imageA   |  imageA   |  
imageB   |  imageB   |  imageB   |  imageB   |  
imageC   |   imageC   |   imageC   |   imageC   |  
imageD   |   imageD   |   imageD   |   imageD   |  

and I need it to look:

imageA   |   imageB   |   imageC   |   imageD   |  
imageE   |   imageF    |   imageG  |   imageH    |  
imageI   |   imageJ     |   imageK   |   imageL    |  
imageM   |   imageN   |   imageO   |   imageP   |  

Hope it's clear enough.
Thank you in advance.
  • 2
1 Solution
what about using a datalist? set the repeatcolumns to 4 ...
techsuppoprtAuthor Commented:
DataList doen'st have a 'Paging' Ability  ( at least not that I know of ) and I'll neet to have pages.
no, paging isn't built into the datalist like a gridview, but it can be done,
from the master himself:
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Cloud Class® Course: C++ 11 Fundamentals

This course will introduce you to C++ 11 and teach you about syntax fundamentals.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now