国产一级a片免费看高清,亚洲熟女中文字幕在线视频,黄三级高清在线播放,免费黄色视频在线看

打開APP
userphoto
未登錄

開通VIP,暢享免費(fèi)電子書等14項(xiàng)超值服

開通VIP
后臺(tái)判斷GridView某列在前臺(tái)顯示信息

后臺(tái)判斷GridView某列在前臺(tái)顯示信息  

2010-08-02 15:56:10|  分類: ★GridView★ |  標(biāo)簽:headertext  boundfield  datafield   |字號(hào) 訂閱

前臺(tái)代碼:

       <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False"
        Width="700px" Font-Size="12px"  BorderWidth="1px" DataKeyNames="VID"
            onrowcommand="GridView1_RowCommand" onrowdatabound="GridView1_RowDataBound" onrowdeleting="GridView1_RowDeleting"  
            >       
            <RowStyle HorizontalAlign="Center" />
        <Columns>
             <asp:BoundField HeaderText="視頻名稱" DataField="NAME_V" />
             <asp:BoundField HeaderText="視頻大小" DataField="VIDEO_SIZE" />
             <asp:BoundField HeaderText="上傳用戶" DataField="USER_ID" />
             <asp:BoundField HeaderText="購買時(shí)間" DataField="UPLOAD_TIME" />
             <asp:BoundField HeaderText="購買手?jǐn)?shù)" DataField="BUY_COUNT" />
             <asp:BoundField DataField="PRODUCT_ID" HeaderText="產(chǎn)品編號(hào)" />
             <asp:BoundField HeaderText="該產(chǎn)品排隊(duì)人數(shù)" />
             <asp:TemplateField HeaderText="查看視頻">
                <ItemTemplate><a href="psnHUOJIA_VIDEO_LOOK.aspx?url=<%# Eval("URL_V")%>">查看視頻</a></ItemTemplate>
             </asp:TemplateField>
             <asp:TemplateField HeaderText="審批">
                <ItemTemplate><a href='psnHUOJIA_VIDEO_SXJIA.aspx?videoid=<%# Eval("VID")%>&proid=<%# Eval("PRODUCT_ID")%>'>通過</a></ItemTemplate>
             </asp:TemplateField>
            <asp:TemplateField HeaderText="刪除">
                <ItemTemplate>
                    <asp:LinkButton ID="LinkButton1" runat="server" OnClientClick="return confirm('是否確認(rèn)刪除該購買信息?')" CommandName="delete" CommandArgument='<%# Eval("VID")%>'>刪除</asp:LinkButton>
                </ItemTemplate>
            </asp:TemplateField>
            <asp:BoundField DataField="VID"/>
        </Columns>
        <HeaderStyle BackColor="#F1F1F1" />
    </asp:GridView>

后臺(tái)代碼:

   public void bangding()
    {
        UploadVideoMGRManager biz = new UploadVideoMGRManager();
        GridView1.DataSource = biz.SelectAll_Video_Biz();
        GridView1.DataBind();
        for (int i = 0; i < GridView1.Rows.Count; i++)
        {
            string aa = GridView1.Rows[i].Cells[5].Text;
            BuyVideoMGRManager bizaa = new BuyVideoMGRManager();
            string pai= bizaa.Select_PaiduiRen(aa);
            int pdui = Convert.ToInt32(pai);
            if (pdui==0)
            {
                GridView1.Rows[i].Cells[6].Text = "<font  color='green'>暫無人使用</font>";
            }
            else
            {
                GridView1.Rows[i].Cells[6].Text = "<font  color='green'>" + pai + "人排隊(duì)</font>";
            }
        }
    }

本站僅提供存儲(chǔ)服務(wù),所有內(nèi)容均由用戶發(fā)布,如發(fā)現(xiàn)有害或侵權(quán)內(nèi)容,請(qǐng)點(diǎn)擊舉報(bào)
打開APP,閱讀全文并永久保存 查看更多類似文章
猜你喜歡
類似文章
在GridView控件中給數(shù)據(jù)列添加超鏈接并傳值的問題解決方法
含有dropdownlist的gridview增刪改查
gridview里金錢格式
GridView 72般絕技
點(diǎn)擊textbox彈出模態(tài)窗口,選擇后返回主頁面并賦值textbox
GridView
更多類似文章 >>
生活服務(wù)
分享 收藏 導(dǎo)長圖 關(guān)注 下載文章
綁定賬號(hào)成功
后續(xù)可登錄賬號(hào)暢享VIP特權(quán)!
如果VIP功能使用有故障,
可點(diǎn)擊這里聯(lián)系客服!

聯(lián)系客服