<%@ Page Title="" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="MakeItem.aspx.cs" Inherits="BiceSurvey.MakeItem" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <br/> <div class="contentbg">  <table id="TABLE3" width="96%" align="center" border="0" runat="server">
        <tr>
            <td width="80%" align="left" class="BannerFont">
                该题目已有项</td>
            <td class="BannerFont" align="center">
                <asp:label id="Label9" runat="server">返 回</asp:label>
            </td>
        </tr>
        <tr>
            <td colSpan="2" align="left">
                <P>
                    <asp:datagrid id="DataGrid3" runat="server" Width="100%" 
                                                AutoGenerateColumns="False" onitemcommand="DataGrid3_ItemCommand" 
                                                oncancelcommand="DataGrid3_CancelCommand" oneditcommand="DataGrid3_EditCommand" 
                                                onupdatecommand="DataGrid3_UpdateCommand" 
                                                onitemdatabound="DataGrid3_ItemDataBound">
                        <AlternatingItemStyle BackColor="#F9F9FF"></AlternatingItemStyle>
                        <ItemStyle Height="25px"></ItemStyle>
                        <HeaderStyle Height="30px" BackColor="AliceBlue"></HeaderStyle>
                        <Columns>
                            <asp:BoundColumn Visible="False" DataField="N_KeyId" ReadOnly="True" HeaderText="编号">
                            </asp:BoundColumn>
                            <asp:BoundColumn DataField="C_KeyTitle" HeaderText="选项内容"></asp:BoundColumn>
                            <asp:BoundColumn DataField="N_OrderId" HeaderText="优先顺序"></asp:BoundColumn>
                            <asp:TemplateColumn HeaderText="类型">
                                <ItemTemplate>
                                    <asp:Label id=Label3 runat="server" Text='<%# Type(DataBinder.Eval(Container, "DataItem.N_Type")) %>'>
															</asp:Label>
                                </ItemTemplate>
                            </asp:TemplateColumn>
                            <asp:BoundColumn DataField="N_Score" HeaderText="分 值"></asp:BoundColumn>
                            <asp:EditCommandColumn ButtonType="LinkButton" UpdateText="更新" HeaderText="编  辑" CancelText="取消" EditText="编  辑">
                            </asp:EditCommandColumn>
                            <asp:TemplateColumn HeaderText="格式限制">
                                <ItemTemplate>
                                    <asp:Label id=Label12 runat="server" Text='<%# GetRuleDB(DataBinder.Eval(Container, "DataItem.N_KeyId")) %>'>
																</asp:Label>
                                </ItemTemplate>
                                <EditItemTemplate>
                                    <asp:DropDownList id=DDLRule runat="server" DataSource='<%#GetRule(DataBinder.Eval(Container, "DataItem.N_KeyId"),DataBinder.Eval(Container, "DataItem.N_Type"))%>' DataTextField="Text" DataValueField="Value">
                                    </asp:DropDownList>
                                </EditItemTemplate>
                            </asp:TemplateColumn>
                            <asp:ButtonColumn Text="删除" HeaderText="删除" CommandName="Del">
                            </asp:ButtonColumn>
                        </Columns>
                    </asp:datagrid>
                    <span class="BannerFont"></asp:datagrid>
											<br>添加调查的选项&nbsp;
											<asp:label id="Label2" runat="server" Visible="False"></asp:label>
                    </span><br/>
                    <br/>选项名称：<asp:textbox id="TextBox3" runat="server"></asp:textbox>
                </P>
                </P>
                <P>
                    <asp:dropdownlist id="DropDownList1" runat="server" Width="152px">
                        <asp:ListItem Value="1">文本行</asp:ListItem>
                        <asp:ListItem Value="5">多行文本</asp:ListItem>
                        <asp:ListItem Value="2">单选</asp:ListItem>
                        <asp:ListItem Value="3">多选</asp:ListItem>
                        <asp:ListItem Value="4">下拉列表</asp:ListItem>
                    </asp:dropdownlist>
                    &nbsp;
											<asp:imagebutton id="ImageButton3" runat="server" ImageUrl="Images/dditem.gif" onclick="ImageButton3_Click">
                    </asp:imagebutton>
                </P>
                <P>
                </P>
                <P>
                </P>
            </td>
        </tr>
    </table></div>
</asp:Content>
