Eval()함수 가 연 결 된 값 에 따라 GridView 의 컨트롤 방법 을 표시 합 니 다.

1860 단어 Eval()귀속GridView

<asp:TemplateField HeaderText=" " ShowHeader="False">
                                <ItemTemplate>
                                <asp:LinkButton ID="btn_zhiding" runat="server" CommandName="Tranfer" CommandArgument='<%#Eval("ARTICLE_ID")%>' Text='<%#Eval("BeTop") == " " ? " ":" " %>' OnCommand="RowCommand"></asp:LinkButton>
                               <asp:PlaceHolder ID="PlaceHolder1"  runat="server" Visible='<% #Eval("BeTop") == " "%>'>
                                <asp:ImageButton ID="imgBtn_OrderUp" runat="server" ImageUrl="~/pic/ .jpg" CommandName="OrderUp"
                                        CommandArgument='<% #Eval("ARTICLE_ID") %>' OnCommand="RowCommand" />
                                    <asp:ImageButton ID="imgBtn_OrderDown" runat="server" ImageUrl="~/pic/ .jpg" CommandName="OrderDown"
                                        CommandArgument='<% #Eval("ARTICLE_ID") %>' OnCommand="RowCommand" />
                                     </asp:PlaceHolder>
                                </ItemTemplate>

                                <ItemStyle HorizontalAlign="Center"/>
                            </asp:TemplateField>
바 인 딩 된 값 에 따라 GridView 의 모든 줄 에 있 는 컨트롤 을 동적 으로 표시 합 니 다.
"

좋은 웹페이지 즐겨찾기