Hi everyone.
I created a Calendar Control container and placed it in a window as control, but I don’t know how to get or return the value when a certain day was pressed.
thank you
Hi everyone.
I created a Calendar Control container and placed it in a window as control, but I don’t know how to get or return the value when a certain day was pressed.
thank you
Are you aware of the DateTime picker built into Xojo? It may do what you want without an extra window?
https://documentation.xojo.com/api/user_interface/controls/datetimepicker.html#datetimepicker
Alternatively, you could add a custom event to your container. For example, DateChanged. You could raise that event any time the control changes date. To do this:
You’re form can then use that event to ‘be informed’ of the chooses date.
Thank very much @Ian_Kennedy … DateTimePicker works. thanks a lot and I will continue developing my control as well with your tips provided. learning is XOJO is fun.
you can define and raise events, also with parameters.
but i would start with DaySelected event and then provide a Methode for SelectedDate which return a DateTime object.