I want to apply formatting to a time that the TimePicker gives me, since it gives me 13:30, but when I want to print it I get 1:30 PM, and I want it to give me 13:30 only.
I attach the code of the _pickTime:
//Función que muestra el Time Picker.
_pickTime() async {
TimeOfDay? timeRecord = await showTimePicker(
context: context,
initialTime: time.replacing(hour: time.hourOfPeriod),
);
if (timeRecord != null) {
setState(() {
finaltime = time.format(context);
});
}
}