Wrox Programmer Forums
|
ASP.NET 1.0 and 1.1 Basics ASP.NET discussion for users new to coding in ASP.NET 1.0 or 1.1. NOT for the older "classic" ASP 3 or the newer ASP.NET 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 1.0 and 1.1 Basics section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old October 21st, 2003, 05:07 AM
Registered User
 
Join Date: Sep 2003
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default Text alignment in datagrid

Hi

Can anyone tell me how to make the text in TextBox1 align to center, moving the ItemStyle tag around does not seem to do anything, the text is always aligned to the left.

Thanks

<asp:TemplateColumn HeaderText="Qty">
<HeaderStyle HorizontalAlign="Center" Width="6%"></HeaderStyle>
<ItemStyle HorizontalAlign="Center"></ItemStyle>
<ItemTemplate>
<asp:TextBox id=TextBox1 runat="server" Width="32px" Text='<%# DataBinder.Eval(Container.DataItem, "Quantity") %>'>
</asp:TextBox>
</ItemTemplate>
<FooterStyle HorizontalAlign="Center"></FooterStyle>
</asp:TemplateColumn>





Similar Threads
Thread Thread Starter Forum Replies Last Post
Datagrid column alignment Ric_H ASP.NET 2.0 Basics 0 October 13th, 2006 02:16 PM
Header Alignment in System.Windows.Foms.DataGrid pushkar ADO.NET 0 March 30th, 2005 02:05 AM
text-alignment anshul HTML Code Clinic 5 July 18th, 2004 01:49 PM
alignment of text on dot matrix using vb...urgent syed rose VB How-To 1 July 8th, 2004 06:45 AM
header text in datagrid msrnivas .NET Web Services 1 March 4th, 2004 01:56 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.