G
geronimi
I want to make a linkbutton column if the column span for that row is
4, if it isn't, make a boundcolumn. These columns are part of a
datagrid. I want to use these code below. In the If statement I want to
check to see if the ColumnSpan = 4, how can I do that? I need the check
the ColumnSpan of the current row, because sometime there is a header
row (spanned over 4 columns) that doen'st need a buttoncolumn
<asp:datagrid id="dgCustomers" runat="server"
AutoGenerateColumns="False" HeaderStyle-CssClass="header4">
<Columns>
<%if not ColumnSpan = 4 then%>
<asp:ButtonColumn DataTextField="Klant" HeaderText="Name"
ItemStyle-CssClass="normal"
ButtonType=LinkButton CommandName="PassSelectedClient"
<asp:BoundColumn DataField="Klant" HeaderText="Name"
ItemStyle-CssClass="normal"
ItemStyle-Width="250px"></asp:BoundColumn>
<%end if%>
<asp:BoundColumn DataField="Klant" HeaderText="Name"
ItemStyle-CssClass="normal"
ItemStyle-Width="250px"></asp:BoundColumn>
<asp:BoundColumn DataField="Address"
HeaderText="Address" ItemStyle-CssClass="normal"
ItemStyle-Width="300px"></asp:BoundColumn>
</Columns>
</asp:datagrid>
4, if it isn't, make a boundcolumn. These columns are part of a
datagrid. I want to use these code below. In the If statement I want to
check to see if the ColumnSpan = 4, how can I do that? I need the check
the ColumnSpan of the current row, because sometime there is a header
row (spanned over 4 columns) that doen'st need a buttoncolumn
<asp:datagrid id="dgCustomers" runat="server"
AutoGenerateColumns="False" HeaderStyle-CssClass="header4">
<Columns>
<%if not ColumnSpan = 4 then%>
<asp:ButtonColumn DataTextField="Klant" HeaderText="Name"
ItemStyle-CssClass="normal"
ButtonType=LinkButton CommandName="PassSelectedClient"
<%else%></asp:ButtonColumn>
<asp:BoundColumn DataField="Klant" HeaderText="Name"
ItemStyle-CssClass="normal"
ItemStyle-Width="250px"></asp:BoundColumn>
<%end if%>
<asp:BoundColumn DataField="Klant" HeaderText="Name"
ItemStyle-CssClass="normal"
ItemStyle-Width="250px"></asp:BoundColumn>
<asp:BoundColumn DataField="Address"
HeaderText="Address" ItemStyle-CssClass="normal"
ItemStyle-Width="300px"></asp:BoundColumn>
</Columns>
</asp:datagrid>