My value localStartDateTime is a LocalDateTime, and used as part of an appointment displayed on a table.
Question:
My value localStartDateTime is a LocalDateTime, and used as part of an appointment displayed on a table. Everything I see shows converting it to a string, however, the variables in appointment call for a localdatetime. I cannot seem to get my formatting to work.
Is there a way to keep the formatting of the string and convert it to a local date time without seeing the "T", or should my appointment variable change from localdatetime to a timestamp?
ZonedDateTime UTCStartTime = startDateTime.atZone(ZoneId.of("UTC"));
ZonedDateTime StartTimeConverted = UTCStartTime.withZoneSameInstant(ZoneId.of(ZoneId.systemDefault().toString()));
LocalDateTime localStartDateTime = StartTimeConverted.toLocalDateTime();
Managerial Accounting Decision Making and Performance Management
ISBN: 978-0273764489
4th edition
Authors: Ray Proctor