<asp:DataList ID="DataList1" runat="server" Width="100%" CellPadding="0" RepeatDirection="Horizontal" RepeatColumns="1" OnItemDataBound="DataList1_ItemDataBound" HorizontalAlign="Center" OnItemCommand="DataList1_ItemCommand"> <ItemTemplate> <div class="tubeblock"> <asp:HyperLink ID="Hyperlink1" runat="server"> <span><span> <asp:Label ID="lblLikes" runat="server" Text='<%# Bind("Img_LikeMark") %>' SkinID="Lbl_listtxt"></asp:Label></span></span><table cellspacing="0" cellpadding="0" width="100%" border="0"> <tbody> <tr> <td valign="top" width="97"> <asp:ImageButton ID="ImageButton1" runat="server" SkinID="imgSmall" ImageUrl='<%# Bind("Image_Name","ThumbnailImages/{0}") %>'> </asp:ImageButton> </td> <td class="listtxt" valign="top"> <asp:Label ID="lblimg_Title" SkinID="LBL_GalleryDisCription" runat="server" Text='<%# Bind("Image_Name") %>'></asp:Label><asp:Label ID="lblDis_bk" SkinID="LBL_GalleryDisCription" runat="server"></asp:Label><asp:Label ID="lblDiscription" runat="server" Text='<%# Bind("Description") %>' Visible="False"></asp:Label><asp:Label ID="lblGalleryID" runat="server" SkinID="LBL_INFO" Visible="False" Text='<%# Bind("Img_Id") %>'></asp:Label><asp:Label ID="lblUrl" runat="server" Visible="False" Text='<%# Bind("Image_Name","ThumbnailImages/{0}") %>'></asp:Label><span></span> </td> </tr> </tbody> </table> </asp:HyperLink> </div> </ItemTemplate> </asp:DataList>
protected void DataList1_ItemCommand(object source, DataListCommandEventArgs e) { Label lblGalleryID = (Label)(e.Item.FindControl("lblGalleryID")); // imgMain.ImageUrl = ((Label)(dl_Gallery.Items[0].FindControl("lblLargeUrl"))).Text.Trim().Replace("~/", ""); Build_ImageGallery1(); }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)