I am using a DateTime Controller with an event validator (Required Field). I need to fire an event when a user clears the DateTime Controller (Empty).

I was trying to do this in DateTimeController_DateChanged Event.

But it doesn’t work. Please let me know if there's any other event, that i can use when the DateTime controller gets cleared.

protected void LeaveStartDateTimeControl_DateChanged(object sender, EventArgs e)

        this.SubmitButton.Enabled = true;

        if (!this.LeaveStartDateTimeControl.IsDateEmpty)
            this.AvailableBalanceLabel.Text = this.PopulateLeaveBalance(this.EmployeeNoTextBox.Text,
                    this.CompanyDropDownList.SelectedItem.Text, this.LeaveStartDateTimeControl.SelectedDate,
            this.AvailableBalanceLabel.Text = string.Empty; 

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.