mcskarthikeyan
asked on
GridView Header Text Direction in Vertical
Hi,
I have a GridView with 6 Columns. I want the last 3 column header text to be displayed in vertical direction. I tried some CSS [writing-mode: tb-rl]. But it is changing all the header text direction. But I need the change only for the last 3 column header.
Thanks
I have a GridView with 6 Columns. I want the last 3 column header text to be displayed in vertical direction. I tried some CSS [writing-mode: tb-rl]. But it is changing all the header text direction. But I need the change only for the last 3 column header.
Thanks
can u share the CSS ?
ASKER
<style type="text/css">
.vert1 th { writing-mode: bt-rl; }
.vert2 th { writing-mode: tb-rl; }
</style>
vert1 is what I am using.
.vert1 th { writing-mode: bt-rl; }
.vert2 th { writing-mode: tb-rl; }
</style>
vert1 is what I am using.
where r u putting this css
i feel the format is wrong
rather it shud be
<style type="text/css">
th.vert1 { writing-mode: bt-rl; }
th.vert2 { writing-mode: tb-rl; }
</style>
i feel the format is wrong
rather it shud be
<style type="text/css">
th.vert1 { writing-mode: bt-rl; }
th.vert2 { writing-mode: tb-rl; }
</style>
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
refer to this url.. may be browser problem.. u can cross check from here
http://msdn.microsoft.com/en-us/library/ms531187(VS.85).aspx
http://msdn.microsoft.com/en-us/library/ms531187(VS.85).aspx
mcskarthikeyan, You can use custom style for any GridView column
Something like this:
<style type="text/css">
.vert1 { writing-mode: bt-rl; }
</style>
...
<asp:GridView ID="GridView1" runat="server" >
<Columns>
<asp:BoundField DataField="MyDataField" HeaderText="<header>"
HeaderStyle-CssClass="vert 1" />
...
</Columns>
</asp:GridView>
Something like this:
<style type="text/css">
.vert1 { writing-mode: bt-rl; }
</style>
...
<asp:GridView ID="GridView1" runat="server" >
<Columns>
<asp:BoundField DataField="MyDataField" HeaderText="<header>"
HeaderStyle-CssClass="vert
...
</Columns>
</asp:GridView>