Hi All
I have a RadDateTime Picker which is enabled / disabled based on the value of a checkbox,
I have just changed the enable disable event from server side to client side, this has caused a problem with the onclick event that i add to the DatePopUpButton on Page Load server side?
The problem is that now when the DatePopupButton is clicked the calendar momentarily appear then disappear??
I have seen another post HERE with a similar problem however i would rathe not use this solution as i want to use the approach that i already have as i have found this more reliable.
Does anybody have any idea why this is happening and how i can cure it please?
Many Thanks
Best Regards
Cush
I have a RadDateTime Picker which is enabled / disabled based on the value of a checkbox,
I have just changed the enable disable event from server side to client side, this has caused a problem with the onclick event that i add to the DatePopUpButton on Page Load server side?
Page Load:
RadDateTimePicker1.DatePopupButton.Attributes.Add("onclick","Myevent(event, '" + RadDateTimePicker1.ClientID + "');return false;")
function Myevent(e, pickerID) {
var datePicker;
datePicker = $find(pickerID);
var textBox = datePicker.get_textBox();
var popupElement = datePicker.get_popupContainer();
var dimensions = datePicker.getElementDimensions(popupElement);
var position = datePicker.getElementPosition(textBox);
var popOffset = (dimensions.height - position.y)
if (popOffset <= 0) {
datePicker.showPopup(position.x, position.y - dimensions.height);
} else {
datePicker.showPopup(position.x, position.y - dimensions.height + popOffset);
}
}
The problem is that now when the DatePopupButton is clicked the calendar momentarily appear then disappear??
I have seen another post HERE with a similar problem however i would rathe not use this solution as i want to use the approach that i already have as i have found this more reliable.
Does anybody have any idea why this is happening and how i can cure it please?
Many Thanks
Best Regards
Cush