This is a migrated thread and some comments may be shown as answers.

Date Navigation buttons

1 Answer 45 Views
Calendar
This is a migrated thread and some comments may be shown as answers.
Jorge
Top achievements
Rank 1
Jorge asked on 06 Sep 2012, 06:03 PM

Hi!

How can I get the next or previous Date when i push the the Navigation button in code behind?
It's possible?

1 Answer, 1 is accepted

Sort by
0
Princy
Top achievements
Rank 2
answered on 07 Sep 2012, 05:20 AM
Hi Jorge,

Here is the sample code that I tried based on your scenario.

JS:
<script type="text/javascript">
 function OnCalendarViewChanged(sender, args)
 {
  __doPostBack("Button1", sender.get_focusedDate());
 }
</script>

C#:
protected void Page_Load(object sender, EventArgs e)
{
 if (Request["__EVENTTARGET"] == "Button1")
 {
  string Date = Request["__EVENTARGUMENT"];
 }
}

Thanks,
Princy.
Tags
Calendar
Asked by
Jorge
Top achievements
Rank 1
Answers by
Princy
Top achievements
Rank 2
Share this question
or