Unhandled Exception: FormatException: Trying to read yyyy from null at position 0

I tried to use dateTime to open or close the access to the registration form, I saved the value of open or close date in my Firebase.. so I must retrieve the date valu...

Using Flutter and Dart, why String variables value is changing over screen transfer?

At my first screen this is the code and result: <pre><code>appController.mydate=DateTime.parse(info.timestamp).toLocal().toString().substring(0, DateTime.parse(inf...

How to parse date time in flutter

I getting below date time from server <pre><code> datetime:2020-07-17T03:18:31.177769-04:00 </code></pre> and I'm using below code to...

How to get date range for a particular week number

I am trying to get date range for a particular week number. Following is my code to get week number with respect to current date <pre><code>final date = D...

The method () was called on null. [Flutter]

In this app, the user will be able to add a task and i wanted to give the option to select the date on which the user wants to save a task (at a later date; one week,...

Passing a value (age) from a widget to another

Through textfield inputs, age of user is obtained with the following code (truncated for simplicity): <pre><code>onChanged: (valueYear) {...

flutter - DateTime.now() not same in my local time

I have a case to check the store opening-closed hours. Im solve this using the code below: <pre><code>final _openHours = 09; final _openMinute = 00; final _closeH...

How to compare 2 hours from dateTime flutter

Im getting an error saying i have wrong hour format when my hour format is 17:30:00 when comparing it to another hour, both my hour here is the code: <pre><code>...

The method toDate was called on null. Receiver: null Tried calling: toDate()

<pre><code>Container( padding: const EdgeInsets.symmetric(horizontal: 10, vertical: 3), alignment: Alignment.bot...

Flutter Grouped ListView: How to sort by Date?

I have a recipe app. Users can save recipes in a weekly planner (using Hive). The date is saved in this format: 2022-09-08 00:00:00.000 (= user wants to cook a recipe...

How can I tell if DateTime.Now() is on a day AFTER a different DateTime

I'm running this on flutter, but I guess this could be a more general issue. I am saving a DateTime in the preferences. I want to be able to then tell if <code...

how can I design Event date from table_calender widget flutter

I want to design the Event Date from table calender flutter, but I can't find the actual event date from the event loader can anyone help with this problem? if I find...

Dart (Flutter) Wrong Time Zone- GMT is set as GMT 0 although my time zone is GMT +1. How can I change it?

Code: DateTime date = DateTime.now(); print(date.timeZoneName); Result : I/flutter (18415): GMT The Result should be GMT +1 Thanks

How to get timezone, Language and County Id in flutter by the location of device in flutter?

I am new to flutter, and I want to get Timezone, language, and county Id when I run my project on my device android or iOS. It should detect Timezone, language and cou...

How can I fetch data from Firebase based on the selected date on calendar?

I have a calendar functions as food log where if user select a particular date on that calendar, it would show all the foods has been consumed only on that selected da...