question

VesoDimov-5835 avatar image
0 Votes"
VesoDimov-5835 asked VesoDimov-5835 edited

Connection between MountCalendar and TextBox

Hello.
Visual Basic - application for Windows.
I have MountCalendar and TextBox. I need help mo make the following: as soon as I mark the day of the calendar in textbox, my choice will appear immediately. At the moment I have made this choice to appear after pressing a button, but I want to change it to appear immediately. Please help me with code.
Regards

PS: I have the same application and for ASP.NET and have the same question.

windows-forms
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

VesoDimov-5835 avatar image
0 Votes"
VesoDimov-5835 answered VesoDimov-5835 edited

Maybe anyone need this code:
On the head on Form ->

 Private Sub MonthCalendar1_DateSelected(sender As Object, e As DateRangeEventArgs) Handles MonthCalendar1.DateSelected
         TextBox2.Text = MonthCalendar1.SelectionRange.Start.Date.ToString("dd.MM.yyyy")
     End Sub
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

VesoDimov-5835 avatar image
0 Votes"
VesoDimov-5835 answered

For ASP.NET code is:

 Private Sub Calendar1_SelectionChanged(sender As Object, e As EventArgs) Handles Calendar1.SelectionChanged
         TextBox7.Text = Calendar1.SelectedDate.ToString("dd.MM.yyyy")
     End Sub
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.