Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > GridView column expanding

Reply
Thread Tools

GridView column expanding

 
 
tshad
Guest
Posts: n/a
 
      10-02-2009
I have a GridView that I want to control all the columns widths except for
1.

Most of them seem to work that way except for this one:

<asp:TemplateField ItemStyle-CssClass="alignRight"
SortExpression="GiftAmount" HeaderStyle-Width="100px" HeaderText="Gift">
<ItemTemplate>
<asp:Label ID="lblGiftAmount" runat="server"
SortExpression="GiftAmount" Width="100px" Text='<%#
Eval("GiftAmount","{0:c}") %>'></asp:Label>
</ItemTemplate>
<EditItemTemplate>
<asp:TextBox ID="txtGiftAmount" runat="server" Width="100px" Text='<%#
Eval("GiftAmount","{0:###,###.00}") %>' />
</EditItemTemplate>
</asp:TemplateField>

I have the Header, Item and Textbox are all set to 100px.

The Grid is set to 100%.

As I expand the grid, this column expands as well. I have another column
that has no size.

Shouldn't that be the only one that expands?

How do I get this column not to expand?

Thanks,

Tom


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
GridView default column too small for description column from data JB ASP .Net 1 09-21-2009 03:04 PM
gridview column values to another page via gridview hyperlink column Keith G Hicks ASP .Net 3 02-18-2008 06:17 AM
1 Gridview. Dropdown A is column from database, Dropdown B is column from database, Data in A and B must be from same row. anonymoushamster@gmail.com ASP .Net 2 11-07-2007 12:40 PM
GridView - Setting the text of the 'select' column to the value of another column Greg Smith ASP .Net 0 04-12-2007 03:11 PM
How to hide a GridView column when the column's Visible property does not support databinding? Keithb ASP .Net 2 10-27-2006 05:02 AM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57