Avatar of mcrmg
mcrmg
 asked on

Width in GridView

Hi,

I am trying to see if I could set the fixed width in GridView. This is what I use based on searching on Internet.

                    <asp:TemplateField HeaderText="Work Phone" SortExpression="WorkPhone" HeaderStyle-Width="20%">
                        <ItemTemplate>
                            <asp:Label ID="WorkPhone" runat="server" Text='<%#Eval("WorkPhone")%>' />
                        </ItemTemplate>
                    </asp:TemplateField>

Open in new window


But it does not work. Am I missing something? thanks
ASP.NET

Avatar of undefined
Last Comment
mcrmg

8/22/2022 - Mon
ASKER CERTIFIED SOLUTION
Ryan Chong

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
mcrmg

ASKER
thank you
I started with Experts Exchange in 2004 and it's been a mainstay of my professional computing life since. It helped me launch a career as a programmer / Oracle data analyst
William Peck