Welcome Guest Search | Active Topics | Sign In | Register

DatePicket scroll event on postback Options
gammadata
Posted: Thursday, September 9, 2010 7:33:08 AM
Rank: Newbie
Groups: Member

Joined: 9/9/2010
Posts: 5
Hello,

I am currently using the datapicker control in an asp.net web page and the scroll event doesn't seem to be fired when scrolling through the months in the popup calendar.

I have set AutoPostBackOnScroll = "True" on the aspx page and created the method in the code :

<eo:DatePicker ID="DatePickerResRtn" runat="server" AllowMultiSelect="False"
AutoPostbackOnScroll="True" AutoPostbackOnSelect="True" ControlSkinID="None"
DayCellHeight="16" DayCellWidth="19" DayHeaderFormat="FirstLetter"
DisabledDates="" OtherMonthDayVisible="True" PickerFormat="dd/MM/yyyy"
SelectedDates="" TitleLeftArrowImageUrl="DefaultSubMenuIconRTL"
TitleRightArrowImageUrl="DefaultSubMenuIcon" VisibleDate="2010-09-01">
<TodayStyle CssText="font-family: tahoma; font-size: 12px; border-right: #bb5503 1px solid; border-top: #bb5503 1px solid; border-left: #bb5503 1px solid; border-bottom: #bb5503 1px solid" />
<SelectedDayStyle CssText="font-family: tahoma; font-size: 12px; background-color: #fbe694; border-right: white 1px solid; border-top: white 1px solid; border-left: white 1px solid; border-bottom: white 1px solid" />
<DisabledDayStyle CssText="background-color:red;border-bottom-color:white;border-bottom-style:solid;border-bottom-width:1px;border-left-color:white;border-left-style:solid;border-left-width:1px;border-right-color:white;border-right-style:solid;border-right-width:1px;border-top-color:white;border-top-style:solid;border-top-width:1px;color:gray;font-family:tahoma;font-size:12px;" />
<PickerStyle CssText="font-family:Courier New; padding-left:5px; padding-right: 5px;" />
<CalendarStyle CssText="background-color: white; border-right: #7f9db9 1px solid; padding-right: 4px; border-top: #7f9db9 1px solid; padding-left: 4px; font-size: 9px; padding-bottom: 4px; border-left: #7f9db9 1px solid; padding-top: 4px; border-bottom: #7f9db9 1px solid; font-family: tahoma" />
<TitleArrowStyle CssText="cursor:hand" />
<DayHoverStyle CssText="font-family: tahoma; font-size: 12px; border-right: #fbe694 1px solid; border-top: #fbe694 1px solid; border-left: #fbe694 1px solid; border-bottom: #fbe694 1px solid" />
<MonthStyle CssText="font-family: tahoma; font-size: 12px; margin-left: 14px; cursor: hand; margin-right: 14px" />
<TitleStyle CssText="background-color:#9ebef5;font-family:Tahoma;font-size:12px;padding-bottom:2px;padding-left:6px;padding-right:6px;padding-top:2px;" />
<OtherMonthDayStyle CssText="font-family: tahoma; font-size: 12px; color: gray; border-right: white 1px solid; border-top: white 1px solid; border-left: white 1px solid; border-bottom: white 1px solid" />
<DayHeaderStyle CssText="font-family: tahoma; font-size: 12px; border-bottom: #aca899 1px solid" />
<DayStyle CssText="font-family: tahoma; font-size: 12px; border-right: white 1px solid; border-top: white 1px solid; border-left: white 1px solid; border-bottom: white 1px solid" />
</eo:DatePicker>

Protected Sub DatePickerRes_Scroll(ByVal sender As Object, ByVal e As System.EventArgs) Handles DatePickerRes.Scroll
'Test
End Sub

Upon reading some older posts on the forum this was identified as a bug, I'm wondering if there is a fix for this available?

I'm using the latest version of Essential Objects (Version 8.0). Any help is greatly appreciated.
eo_support
Posted: Thursday, September 9, 2010 8:30:01 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,194
Hi,

The only case where Scroll event will be fired on DatePicker is when you also handle DayRender event. Otherwise the DatePicker will not fire Scroll event even AutoPostBackOnScroll is set to true. If you have no intention to do custom rendering, you can simply handle the DayRender event and put the following code in there:

e.Writer.Write(e.Day.DayNumberText)

Hope this helps. Please feel free to let us know if you still have any questions.

Thanks!
gammadata
Posted: Thursday, September 9, 2010 8:55:42 AM
Rank: Newbie
Groups: Member

Joined: 9/9/2010
Posts: 5
Hello,

It is firing the event now, thanks very much for your help!

eo_support
Posted: Thursday, September 9, 2010 9:04:10 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,194
You are welcome. Please feel free to let us know if you have any more questions.


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.