ASP.NET NextPrevStyle Property
Definition and Usage
The NextPrevStyle property is used to set and return the style of the next month and previous month links in the calendar:
Syntax
<asp:Calendar runat="server"> <NextPrevStyle style="value" /> </asp:Calendar>
Or:
<asp:Calendar runat="server" NextPrevStyle-style="value" />
Property | Description |
---|---|
style | Specify the style to be set. See Style Control, to view possible styles and their values. |
value | Specify the value of the specified style. |
Example
Example 1
The following example shows one method of setting the NextPrevStyle property of the calendar:
<form runat="server"> <asp:Calendar id="cal1" runat="server"> <NextPrevStyle ForeColor="#FF0000" /> </asp:Calendar> </form>
Example 2
The following example shows another method of setting the NextPrevStyle property of the calendar:
<form runat="server"> <asp:Calendar id="cal2" runat="server"> NextPrevStyle-ForeColor="#FF0000" /> </form>
Example
- Set the NextPrevStyle of the Calendar Control
- Set the NextPrevStyle of the Calendar Control (with declaration and script)