Helper function to work with Date picker controll