controls in wrong column

J

jake

My datagrid has several bound columns followed by a template column
containing a checkbox(in ItemTemplate), followed by three template
columns, each with hyperlinks(in ItemTemplate).

The problem is that when this datagrid displays, the hyperlink columns
are shifted over into the template column that should contain
checkboxes. The column headings are as they should be. The last
column is empty when it should contain hyperlinks.

Thanks for any aid you can provide!

<Columns>
<asp:BoundColumn DataField="WPDESC" HeaderText="PRODUCT
DESCRIPTION">
<ItemStyle Wrap="False" HorizontalAlign="Left"></ItemStyle>
</asp:BoundColumn>
<asp:BoundColumn DataField="UOM" HeaderText="UOM">
<ItemStyle HorizontalAlign="Left" Width="35px"></ItemStyle>
</asp:BoundColumn>
<asp:BoundColumn DataField="CurrUnits"
HeaderText="YTD&lt;BR&gt;UNITS" DataFormatString="{0:N}">
<ItemStyle HorizontalAlign="Right" Width="70px"></ItemStyle>
</asp:BoundColumn>
<asp:BoundColumn DataField="CurrSales$"
HeaderText="YTD&lt;BR&gt;SALES$" DataFormatString="{0:c}">
<ItemStyle HorizontalAlign="Right"></ItemStyle>
</asp:BoundColumn>
<asp:BoundColumn DataField="CurrGP_Perc"
HeaderText="YTD&lt;br&gt;GP%" DataFormatString="{0:N}">
<ItemStyle Wrap="False" HorizontalAlign="Right"></ItemStyle>
</asp:BoundColumn>
<asp:BoundColumn DataField="PriorUnits"
HeaderText="PRIOR&lt;br&gt;UNITS" DataFormatString="{0:N}">
<ItemStyle HorizontalAlign="Right" Width="70px"></ItemStyle>
</asp:BoundColumn>
<asp:BoundColumn DataField="PriorSales$"
HeaderText="PRIOR&lt;br&gt;SALES$" DataFormatString="{0:c}">
<ItemStyle HorizontalAlign="Right"></ItemStyle>
</asp:BoundColumn>
<asp:BoundColumn DataField="PriorGP_Perc"
HeaderText="PRIOR&lt;br&gt;GP%" DataFormatString="{0:N}">
<ItemStyle Wrap="False" HorizontalAlign="Right"></ItemStyle>
</asp:BoundColumn>
<asp:BoundColumn DataField="Diff" HeaderText="CHANGE&lt;BR&gt;$"
DataFormatString="{0:c}">
<ItemStyle HorizontalAlign="Right"></ItemStyle>
</asp:BoundColumn>
<asp:BoundColumn DataField="DiffPerc"
HeaderText="CHANGE&lt;BR&gt;%" DataFormatString="{0:N}">
<ItemStyle HorizontalAlign="Right"></ItemStyle>
</asp:BoundColumn>
<asp:TemplateColumn HeaderText="CHART&lt;BR&gt;SELECT">
<ItemStyle Width="20px"></ItemStyle>
<ItemTemplate>
<asp:CheckBox id="chkSelection1" runat="server"></asp:CheckBox>
<asp:Label id=hdnDataDesc Runat="server"
Text='<%#DataBinder.Eval(Container.DataItem, "WPDESC")%>'
Visible="False">
</asp:Label>
<asp:Label id=hdnCurrSalesDollars Runat="server"
Text='<%#DataBinder.Eval(Container.DataItem, "CurrSales$")%>'
Visible="False">
</asp:Label>
<asp:Label id=hdnCurrGP Runat="server"
Text='<%#DataBinder.Eval(Container.DataItem, "CurrGP_Perc")%>'
Visible="False">
</asp:Label>
<asp:Label id=hdnPriorSalesDollars Runat="server"
Text='<%#DataBinder.Eval(Container.DataItem, "PriorSales$")%>'
Visible="False">
</asp:Label>
<asp:Label id=hdnPriorGP Runat="server"
Text='<%#DataBinder.Eval(Container.DataItem, "PriorGP_Perc")%>'
Visible="False">
</asp:Label>
</ItemTemplate>
</asp:TemplateColumn>
<asp:TemplateColumn HeaderText="BY&lt;BR&gt;CUSTOMER">
<ItemStyle Wrap="False"></ItemStyle>
<ItemTemplate>
<asp:Hyperlink runat="server" ID="Hyperlink2"></asp:Hyperlink>
</ItemTemplate>
</asp:TemplateColumn>
<asp:TemplateColumn HeaderText="BY&lt;BR&gt;SLSMN">
<ItemStyle Wrap="False"></ItemStyle>
<ItemTemplate>
<asp:Hyperlink runat="server"
ID="Hyperlinkcolumn1"></asp:Hyperlink>
</ItemTemplate>
</asp:TemplateColumn>
<asp:TemplateColumn HeaderText="BY&lt;BR&gt;MONTH">
<ItemStyle Wrap="False"></ItemStyle>
<ItemTemplate>
<asp:Hyperlink runat="server" ID="Hyperlink1"></asp:Hyperlink>
</ItemTemplate>
</asp:TemplateColumn>
</Columns>
 
J

jake

Sheepishly...I figured out my own post. I had moved the column with
checkboxes within the datagrid but forgot to move the hyperlink urls to
the new cell locations.

jake
 
J

jake

Sheepishly...I figured out my own post. I had moved the column with
checkboxes within the datagrid but forgot to move the hyperlink urls to
the new cell locations.

jake
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,969
Messages
2,570,161
Members
46,705
Latest member
Stefkari24

Latest Threads

Top