Reputation: 103
I am trying to apply this css class to asp.net GRIDVIEW PAGER but not getting applied except Margin properties.
.gvwCasesPager a {
margin-left:5px;
margin-right:5px;
text-align:center;
font-size:small;
font-style:normal;
height: 40px;
}
pager in gv:
<PagerStyle HorizontalAlign="Center"
CssClass="gvwCasesPager"
Font-Size="Small"
Font-Bold="true"
Height="40px" />
Browser Output:
<tr class="gvwCasesPager" align="center" style="font-size:Small;font-weight:bold;height:40px;">
<td colspan="10">
<table>
<tbody>
<tr>
<td><span>1</span></td>
<td><a href="javascript:__doPostBack('ctl00$ContentPlaceHolder1$grdviewPersonalInformation','Page$2')">2</a></td>
</tr>
</tbody>
</table>
</td>
</tr>
Upvotes: 0
Views: 163
Reputation: 21406
Use following markup for pager. Your original markup had the same CSS attributes that you were trying to set in the Css class for pager, and that was causing the Css class to be overridden.
<PagerStyle HorizontalAlign="Center" CssClass="gvwCasesPager"/>
Upvotes: 2