Please, could you help me and tell me how can I generated dynamically this piece of code:
<li>
<a href="../adGallery/images/pictures/1.jpg">
<img src="../adGallery/images/pictures/thumbs/1.jpg" class="image0"/>
</a>
</li>
<li>
<a href="../adGallery/images/pictures/2.jpg">
<img src="../adGallery/images/pictures/thumbs/2.jpg" title="A title for 10.jpg" alt="This is a nice, and incredibly descriptive, description of the image 10.jpg" class="image1"/>
</a>
</li>
from my code behind?
Thank you very much
Use an asp:Repeater control.
Here is a tutorial on doing exactly this kind of thing:
http://www.codeguru.com/csharp/.net/net_asp/controls/article.php/c19299/The-ASPNET-Repeater-Web-Server-Control.htm
Use this code method:
and place a label in the required position and bind the result to that label
This will render as required HTML
I would suggest to use a
Repeater
which enables to customize your controls as much as possible. ABulletedList
control is limited. Here's an attempt anyway:codebehind: