This was a great series! I like how the episodes are shorter because there are many things that if I'm confused about, I can go search outside and read to find out what it means/go deeper. Having the option of going deeper is more efficient to me than sitting through 1-2 hours of a lecture. Thanks so much!!!
I have watched many sqflite tutorials from youtube, But this channel is the best. Thank you sir, Very clear to understand your Step by step guides. SO Thank you,Thank you again. Now I have subscribed You
This lecture seemed rushed through ! Would have been better if we were presented "why" we are doing certain operations and benefits of doing them. There seem to be multiple ways of working with say routes. But why was the specific approach chosen in the lecture.
I wanted to just learn SQflite, but as a pre-req I had to watch all of his previous module 4 to finally regret at section 4.8 how badly its been walked through. Time totally not worth it; for a simple concept ended up spending hours of watching video.
Thanks once again Smartherd, You are a blessing to us all most especially me. please I will appreciate if one more session can be added to this tutorial to cover the null safety part that is just introduced by flutter. As it seems difficult to follow along if using the latest version of flutter. Please few minutes video tutorial will be appreciated explaining how to make the app function properly. thansk
When I am giving the title and descripition in 2nd screen and pressing Save I m directed to 1st screen which is fine but I am not able to see the card of note the screen is full blank as previous. Please help anyone!!!
final notekeeper project not showing up the notes added in the main screen. Tried using smart nerd GitHub code also. Same issue . Everything is working but after clicking the save button the main screen appears to be plain. did anyone get the same issue?
Thanks you Smartherd! Being a Flutter developer beginer I gone through all vedios and all are very well explained. However I downloaded the source code from github for 8th video which is giving many build error. FYI, my Android Studio vesion is Android Studio Flamingo | 2022.2.1
Excellent work! A small question why it need this two lines to initialize database. getNoteList() itself initialize the database, no? 1: final Future dbFuture = databaseHelper.initializeDatabase(); 2: dbFuture.then((database) { Future noteListFuture = databaseHelper.getNoteList();
Edit: my bad it was a typo i missed the _ on the model i get this error, im not sure why, Future and awaits already there Exception has occurred. NoSuchMethodError (NoSuchMethodError: The method 'query' was called on null. Receiver: null Tried calling: query("note_table", orderBy: "priority ASC"))
@smarherd Bro i am facing some issue getting(DatabaseException(table note_table has no column named date (code 1): , while compiling: INSERT INTO note_table (title, description, priority, date) VALUES (?, ?, ?, ?)) sql 'INSERT INTO note_table (title, description, priority, date) VALUES (?, ?, ?, ?)' args [cggf, cgugdfu, 2, Jan 20, 2019]}) error could you please help me to resolve this issue.
Due to Null Safety in the latest version of Flutter, my application gets crashes when I press FAB and gives this error "expected a value of type string but got one of type null " at "return NoteDetail(note, title);" in note_list.dart file . Does anyone know how to resolve this?
Can we do this using provider? Hope it will be much easier then... I am confused with this tutorial..till the previous video i understand everything but this one is really confusing for me..
instead of priority i included roll no u set priority as 2 nd wen u chng it it gets changed but wen i set roll no. as 1 it is displaying tht only even after chnging the value
Can u plzz help me I am trying to find how to solve this error from 3 days but to no avail. I am getting this error when i click save button The setter 'firstName=' was called on null. Receiver: null Tried calling: firstName="J" The setter 'firstName=' was called on null. Receiver: null Tried calling: firstName="Ja" like this for all the textfields used. I am trying out an app watching ur tutorial n m stuck here. Please do help me. How to solve this error.
I was having the same errors where the save button just wasn't working. After carefully going through the code I realized that it was because of a typo when creating the database causing there to be an error, here's how it should be: void _createDb(Database db, int newVersion) async { await db.execute('CREATE TABLE $noteTable ($colId INTEGER PRIMARY KEY AUTOINCREMENT, ' '$colTitle TEXT, $colDescription TEXT, $colPriority INTEGER, $colDate TEXT)'); } In the video he used "helper" out of nowhere, what you have to do is similar to the note_list.dart, you've got to access it on note_detail.dart, Add this in your extended State: DatebaseHelper helper = DatabaseHelper(); Hope this helps ^^ On a final note be sure if you're running it on your Android phone directly to have migrated to AndroidX. Happy coding and Happy New Year's!! ^o^
i have made these chnges its wrking fine on emulator but when i build apk and run it on my mobile phone i am not able to view the list after saving the data the screen is blank
While running the app, at the initial stage ,I am getting following error. Syncing files to device Redmi Note 5 Pro... I/flutter (20894): ══╡ EXCEPTION CAUGHT BY WIDGETS LIBRARY ╞═══════════════════════════════════════════════════════════ I/flutter (20894): The following NoSuchMethodError was thrown building NoteList(dirty, state: _NoteListState#e9138): I/flutter (20894): The method 'initializeDatabase' was called on null. I/flutter (20894): Receiver: null I/flutter (20894): Tried calling: initializeDatabase() Pls tell me solution..
Good video but for beginner its going to be little difficult to absorb. Instead of writing all methods like a big bang, you could have written code solution feature wise. Like first populate all task list via select query, then move on to delete button & delete query.. accordingly this way learns able to see the result of every method action.
@@lakshandersagwal I felt this tutorial is pulling the motivation down. I purchashed a udemy course and finished the sqflite in 2 hours. Happy to share code or link to the tutorial
What is the solution of this Error: MissingPluginException(No implementation found for method getApplicationDocumentsDirectory on channel plugins.flutter.io/path_provider)
Hi, i have an issue and i hope you would be of help. I added some other priorities to the _priorities variable ... updated the updatePriorityAsInt() method and the getPriorityAsString() method, to reflect the new _priorities list. I also updated the getPriorityColor() method in the note_list.dart file, to reflect these changes. however, the drop down lists is only switching between High and Low priorities. Please could you help ?
While trying to save, I am getting an error message like this. Please suggest. [ERROR:flutter/lib/ui/ui_dart_state.cc(157)] Unhandled Exception: DatabaseException(table note_table has no column named date (code 1 SQLITE_ERROR): , while compiling: INSERT INTO note_table (title, description, priority, date) VALUES (?, NULL, ?, ?)) sql 'INSERT INTO note_table (title, description, priority, date) VALUES (?, NULL, ?, ?)' args [, 2, Feb 9, 2020]}
I can't view the insert in the list because it is not update. for solve it bug. you can insert in note_list.dart into NoteListState @override void initState() { // TODO: implement initState updateListView(); //forzar a que liste el elemento recién creado super.initState(); } When the app return to firstScreen the list would be update :)
Nice tutorial. I have few questions in it. If a item is deleted or added, is it a good approach to fetch all the items again. And I should be able fetch 10-10 items rather than fetching all items. It might create an issue if note list will be 1000 or more. Thanks
I am getting this error. on a red screen The getter 'firstName' was called on null. Receiver: null Tried calling: firstName Can u help me by telling y i m getting this error n how can i solve it plzzzzzz I learnt flutter watching ur video n m trying to develop an app for my clg project. Now I am stuck here from 3 days. plzz help me
Erroe in WillPopScope, The function has return type Future ,but does not end with return statement . file name: note_detail.dart [45,17]. Same error in my code and and code downloaded from github.
When i add or delete note object in delete view it directs to note_list view so here the note_list is not updated on the spot. But when i close and reopen the app, i can see the updated content in note_list. whats the problem here?
So I am facing a problem if anybody can help. For Some Reason,only the 'priority' instance variable of the Note class seems to not be getting inserted and updated in the database. Rest all are working fine. When I checked through debugPrint() the value of priority in 'NoteDetail ' class, it shows 'null'. (As a result all my notes are by default of 'null' priority and of yellow background) Using debugPrint(), I have checked, right upto just before the point where database is Inserted & Updated and I have got proper values for priority(ie 1or 2). Only when I check it on retrieval, does it show 'null'. I am using the same functions db.insert() and db.update() as @Smartherd for Insertion and Updation. I also tried adding note.priority to whereArgs attribute in db.update(), but to no avail. Can Anybody guess where the problem lies. Thanks.
@@lakshandersagwal Nope. I tried certain things (for example using the rawInsert() function) but they resulted in different kind of errors(Run Time Exceptions). I am only a beginner in Flutter so don't know much what else to try. 🤷♂️
void navigateToDetail(Note note, String title) async{ int? result = await Navigator.push(context, MaterialPageRoute(builder: (context){ return NoteDetail(note, title); })); if(result == true){ updateListView(); } } The following _CastError was thrown building NoteDetail(dirty, dependencies: [_InheritedTheme, _LocalizationsScope-[GlobalKey#44e71]], state: NoteDetailState#02499): Null check operator used on a null value plz give me this problems solution.
pls make a tutorial on how to add a note to each listview item. for example, the constitution of india. when you click an article you can either highlight or add notes no need for another screen just pop up
Erroe in WillPopScope, The function has return type Future ,but does not end with return statement . file name: note_detail.dart [45,17]. Same error in my code and and code downloaded from github. Please Reply.
Error running Gradle: ProcessException : process "c:\users\appname\ Android\gradlew.bat " excited abnormally: > Configure project: sqflite Iam getting this error continuously If anyone knows about this error ..pls tell how to solve. Thanks in advance
got these error from the source code: I/flutter ( 9786): ══╡ EXCEPTION CAUGHT BY WIDGETS LIBRARY ╞═══════════════════════════════════════════════════════════ I/flutter ( 9786): The following assertion was thrown building Builder(dirty): I/flutter ( 9786): Looking up a deactivated widget's ancestor is unsafe. I/flutter ( 9786): At this point the state of the widget's element tree is no longer stable. To safely refer to a I/flutter ( 9786): widget's ancestor in its dispose() method, save a reference to the ancestor by calling I/flutter ( 9786): inheritFromWidgetOfExactType() in the widget's didChangeDependencies() method.
10 mins past and the code is not executed even once.. just code code code and code.. finally get lost ... Please seriously consider making tutorials that is bit sized, absorbed and relatable to learners.
This video lecture was too fast and need to watch again and again for understanding.. In this you perform all tasks well but did not teach as much as you can.
int result = await helper.deleteNote(note.id); int result = await databaseHelper.deleteNote(note.id); error: The argument type 'int' can't be assigned to the parameter type 'Note'. (argument_type_not_assignable at [database] lib\screens ote_list.dart:116)
In database_helper.dart, you would have in the method deleteNote like this: Future deleteNote(int id). it´s possible that you have in the parameter (Note note)
This was a great series! I like how the episodes are shorter because there are many things that if I'm confused about, I can go search outside and read to find out what it means/go deeper. Having the option of going deeper is more efficient to me than sitting through 1-2 hours of a lecture. Thanks so much!!!
I have watched many sqflite tutorials from youtube, But this channel is the best. Thank you sir, Very clear to understand your Step by step guides. SO Thank you,Thank you again. Now I have subscribed You
This lecture seemed rushed through ! Would have been better if we were presented "why" we are doing certain operations and benefits of doing them. There seem to be multiple ways of working with say routes. But why was the specific approach chosen in the lecture.
Totally agree.
I wanted to just learn SQflite, but as a pre-req I had to watch all of his previous module 4 to finally regret at section 4.8 how badly its been walked through. Time totally not worth it; for a simple concept ended up spending hours of watching video.
I m not going to watch this any further, however thanks and grateful for all the previous videos.
The whole series was good. But I felt instead of explaining every bit at the end or in this video you just rushed to complete the app.
Seems too fast and messy still, thank you for this series!!HELPFUL!
Thank you thank you thank you...............1000 times.....please keep posting more video on flutter
Thanks once again Smartherd, You are a blessing to us all most especially me.
please I will appreciate if one more session can be added to this tutorial to cover the null safety part that is just introduced by flutter. As it seems difficult to follow along if using the latest version of flutter.
Please few minutes video tutorial will be appreciated explaining how to make the app function properly.
thansk
it would be better if we were seeing the changes on the app after every new feature is added.
Exactly!
When I am giving the title and descripition in 2nd screen and pressing Save I m directed to 1st screen which is fine but I am not able to see the card of note the screen is full blank as previous.
Please help anyone!!!
Why did you initialized database manually in updateListView() when we already did that in the database getter !!
Thank you very much. Any help on how to use SQFLITE for quiz app in flutter?
final notekeeper project not showing up the notes added in the main screen. Tried using smart nerd GitHub code also. Same issue . Everything is working but after clicking the save button the main screen appears to be plain. did anyone get the same issue?
Thanks you Smartherd! Being a Flutter developer beginer I gone through all vedios and all are very well explained. However I downloaded the source code from github for 8th video which is giving many build error. FYI, my Android Studio vesion is Android Studio Flamingo | 2022.2.1
Excellent work! A small question why it need this two lines to initialize database. getNoteList() itself initialize the database, no?
1: final Future dbFuture = databaseHelper.initializeDatabase();
2: dbFuture.then((database) {
Future noteListFuture = databaseHelper.getNoteList();
if (result == true) is exactly the same as if (result).
Yes, your are right..
Yes
look at you man, I find you
the tutorial is very nice thank you sir,
Hello Sir,
While trying to save, I am getting an error message like this.
Please suggest.
I/flutter ( 5794): ══╡ EXCEPTION CAUGHT BY WIDGETS LIBRARY ╞═══════════════════════════════════════════════════════════
I/flutter ( 5794): The following assertion was thrown building Builder(dirty):
I/flutter ( 5794): Looking up a deactivated widget's ancestor is unsafe.
I/flutter ( 5794): At this point the state of the widget's element tree is no longer stable. To safely refer to a
I/flutter ( 5794): widget's ancestor in its dispose() method, save a reference to the ancestor by calling
I/flutter ( 5794): inheritFromWidgetOfExactType() in the widget's didChangeDependencies() method.
I/flutter ( 5794):
I/flutter ( 5794): When the exception was thrown, this was the stack:
I/flutter ( 5794): #0 Element._debugCheckStateIsActiveForAncestorLookup. (package:flutter/src/widgets/framework.dart:3252:9)
I/flutter ( 5794): #1 Element._debugCheckStateIsActiveForAncestorLookup (package:flutter/src/widgets/framework.dart:3261:6)
I/flutter ( 5794): #2 Element.inheritFromWidgetOfExactType (package:flutter/src/widgets/framework.dart:3276:12)
I/flutter ( 5794): #3 Theme.of (package:flutter/src/material/theme.dart:128:52)
I/flutter ( 5794): #4 showDialog. (package:flutter/src/material/dialog.dart:705:37)
I/flutter ( 5794): #5 _DialogRoute.buildPage (package:flutter/src/widgets/routes.dart:1484:14)
I/flutter ( 5794): #6 _ModalScopeState.build. (package:flutter/src/widgets/routes.dart:655:43)
I/flutter ( 5794): #7 Builder.build (package:flutter/src/widgets/basic.dart:6035:41)
I/flutter ( 5794): #8 StatelessElement.build (package:flutter/src/widgets/framework.dart:3789:28)
I/flutter ( 5794): #9 ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:3736:15)
I/flutter ( 5794): #10 Element.rebuild (package:flutter/src/widgets/framework.dart:3559:5)
I/flutter ( 5794): #11 StatelessElement.update (package:flutter/src/widgets/framework.dart:3796:5)
I/flutter ( 5794): #12 Element.updateChild (package:flutter/src/widgets/framework.dart:2748:15)
I/flutter ( 5794): #13 SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:4883:14)
I/flutter ( 5794): #14 Element.updateChild (package:flutter/src/widgets/framework.dart:2748:15)
I/flutter ( 5794): #15 SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:4883:14)
I/flutter ( 5794): #16 Element.updateChild (package:flutter/src/widgets/framework.dart:2748:15)
I/flutter ( 5794): #17 SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:4883:14)
I/flutter ( 5794): #18 Element.updateChild (package:flutter/src/widgets/framework.dart:2748:15)
I/flutter ( 5794): #19 ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:3747:16)
I/flutter ( 5794): #20 Element.rebuild (package:flutter/src/widgets/framework.dart:3559:5)
I/flutter ( 5794): #21 StatefulElement.update (package:flutter/src/widgets/framework.dart:3894:5)
I/flutter ( 5794): #22 Element.updateChild (package:flutter/src/widgets/framework.dart:2748:15)
I/flutter ( 5794): #23 SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:4883:14)
I/flutter ( 5794): #24 Element.updateChild (package:flutter/src/widgets/framework.dart:2748:15)
I/flutter ( 5794): #25 ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:3747:16)
I/flutter ( 5794): #26 Element.rebuild (package:flutter/src/widgets/framework.dart:3559:5)
I/flutter ( 5794): #27 ProxyElement.update (package:flutter/src/widgets/framework.dart:4006:5)
I/flutter ( 5794): #28 Element.updateChild (package:flutter/src/widgets/framework.dart:2748:15)
I/flutter ( 5794): #29 SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:4883:14)
I/flutter ( 5794): #30 Element.updateChild (package:flutter/src/widgets/framework.dart:2748:15)
I/flutter ( 5794): #31 ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:3747:16)
I/flutter ( 5794): #32 Element.rebuild (package:flutter/src/widgets/framework.dart:3559:5)
I/flutter ( 5794): #33 StatefulElement.update (package:flutter/src/widgets/framework.dart:3894:5)
I/flutter ( 5794): #34 Element.updateChild (package:flutter/src/widgets/framework.dart:2748:15)
I/flutter ( 5794): #35 ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:3747:16)
I/flutter ( 5794): #36 Element.rebuild (package:flutter/src/widgets/framework.dart:3559:5)
I/flutter ( 5794): #37 StatelessElement.update (package:flutter/src/widgets/framework.dart:3796:5)
I/flutter ( 5794): #38 Element.updateChild (package:flutter/src/widgets/framework.dart:2748:15)
I/flutter ( 5794): #39 SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:4883:14)
I/flutter ( 5794): #40 Element.updateChild (package:flutter/src/widgets/framework.dart:2748:15)
I/flutter ( 5794): #41 ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:3747:16)
I/flutter ( 5794): #42 Element.rebuild (package:flutter/src/widgets/framework.dart:3559:5)
I/flutter ( 5794): #43 ProxyElement.update (package:flutter/src/widgets/framework.dart:4006:5)
I/flutter ( 5794): #44 Element.updateChild (package:flutter/src/widgets/framework.dart:2748:15)
I/flutter ( 5794): #45 ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:3747:16)
I/flutter ( 5794): #46 Element.rebuild (package:flutter/src/widgets/framework.dart:3559:5)
I/flutter ( 5794): #47 BuildOwner.buildScope (package:flutter/src/widgets/framework.dart:2273:33)
I/flutter ( 5794): #48 _WidgetsFlutterBinding&BindingBase&GestureBinding&ServicesBinding&SchedulerBinding&PaintingBinding&SemanticsBinding&RendererBinding&WidgetsBinding.drawFrame (package:flutter/src/widgets/binding.dart:700:20)
I/flutter ( 5794): #49 _WidgetsFlutterBinding&BindingBase&GestureBinding&ServicesBinding&SchedulerBinding&PaintingBinding&SemanticsBinding&RendererBinding._handlePersistentFrameCallback (package:flutter/src/rendering/binding.dart:268:5)
I/flutter ( 5794): #50 _WidgetsFlutterBinding&BindingBase&GestureBinding&ServicesBinding&SchedulerBinding._invokeFrameCallback (package:flutter/src/scheduler/binding.dart:988:15)
I/flutter ( 5794): #51 _WidgetsFlutterBinding&BindingBase&GestureBinding&ServicesBinding&SchedulerBinding.handleDrawFrame (package:flutter/src/scheduler/binding.dart:928:9)
I/flutter ( 5794): #52 _WidgetsFlutterBinding&BindingBase&GestureBinding&ServicesBinding&SchedulerBinding._handleDrawFrame (package:flutter/src/scheduler/binding.dart:840:5)
I/flutter ( 5794): #56 _invoke (dart:ui/hooks.dart:209:10)
I/flutter ( 5794): #57 _drawFrame (dart:ui/hooks.dart:168:3)
I/flutter ( 5794): (elided 3 frames from package dart:async)
I/flutter ( 5794): ════════════════════════════════════════════════════════════════════════════════════════════════════
I am also getting error. Have your issue been reolved?
I have some trouble with code. The source code link may be expired. can you please share it again?
Edit: my bad it was a typo i missed the _ on the model
i get this error, im not sure why, Future and awaits already there
Exception has occurred.
NoSuchMethodError (NoSuchMethodError: The method 'query' was called on null.
Receiver: null
Tried calling: query("note_table", orderBy: "priority ASC"))
3 positional argument(s) expected, but 2 found.
sir i have a problen in this vedio where is the issue occur
i follow them stem by step
I made this app But the saving is not shown on screen ??
It is Shown as a Blank White Screen as earlier.
Please Help me with this.
same with me
i am facing the same problem have you got the solution pls tell me.
I just compare the code.. which is available on github site and make the changes
@@buildwithcodex have you remember what you change in it
Or where
Not Actually.
I AM HAVING TROUBLE WITH THE CODE......help me....while saving is occuring in console and the fuction in not working please help in this case........
@smarherd Bro i am facing some issue getting(DatabaseException(table note_table has no column named date (code 1): , while compiling: INSERT INTO note_table (title, description, priority, date) VALUES (?, ?, ?, ?)) sql 'INSERT INTO note_table (title, description, priority, date) VALUES (?, ?, ?, ?)' args [cggf, cgugdfu, 2, Jan 20, 2019]}) error could you please help me to resolve this issue.
spelling mistake of date possible may in map["date"]
Use this code for getting the path String path=join(directory.path, "maindb.db");
instead of what is given in the video.
@@anandgupta8529 it says join method is not in class helper..
Its showing inactive Input Connection and then Problem saving or deleting the node. Any idea how to solve this
If anyone is having trouble when typing in the TextField...
You might want to check this:
github.com/flutter/flutter/issues/31512
Due to Null Safety in the latest version of Flutter, my application gets crashes when I press FAB and gives this error "expected a value of type string but got one of type null " at "return NoteDetail(note, title);" in note_list.dart file . Does anyone know how to resolve this?
Can we do this using provider? Hope it will be much easier then... I am confused with this tutorial..till the previous video i understand everything but this one is really confusing for me..
Super
Another exception was thrown: RangeError (index): Invalid value: Valid value range is empty: 0
slam borhter
instead of priority i included roll no u set priority as 2 nd wen u chng it it gets changed but wen i set roll no. as 1 it is displaying tht only even after chnging the value
Can u plzz help me I am trying to find how to solve this error from 3 days but to no avail.
I am getting this error when i click save button
The setter 'firstName=' was called on null.
Receiver: null
Tried calling: firstName="J"
The setter 'firstName=' was called on null.
Receiver: null
Tried calling: firstName="Ja"
like this for all the textfields used. I am trying out an app watching ur tutorial n m stuck here. Please do help me. How to solve this error.
With some animations, it will be great :) thanks.
Animation series will come soon
LateInitializationError: Field '_databaseHelper' has not been initialized.
How to solve this
What's the logic behind notes appearing according to their priority on the UI screen? where have we used it?
Thank you
Instead of gestureDetector could we directly use the iconbutton?
I was having the same errors where the save button just wasn't working. After carefully going through the code I realized that it was because of a typo when creating the database causing there to be an error, here's how it should be:
void _createDb(Database db, int newVersion) async {
await db.execute('CREATE TABLE $noteTable ($colId INTEGER PRIMARY KEY AUTOINCREMENT, '
'$colTitle TEXT, $colDescription TEXT, $colPriority INTEGER, $colDate TEXT)');
}
In the video he used "helper" out of nowhere, what you have to do is similar to the note_list.dart, you've got to access it on note_detail.dart, Add this in your extended State:
DatebaseHelper helper = DatabaseHelper();
Hope this helps ^^
On a final note be sure if you're running it on your Android phone directly to have migrated to AndroidX.
Happy coding and Happy New Year's!! ^o^
Thanks for the help, it worked for me but I don't understand how these changes make it work..
i have made these chnges its wrking fine on emulator but when i build apk and run it on my mobile phone i am not able to view the list after saving the data the screen is blank
While running the app, at the initial stage ,I am getting following error.
Syncing files to device Redmi Note 5 Pro...
I/flutter (20894): ══╡ EXCEPTION CAUGHT BY WIDGETS LIBRARY ╞═══════════════════════════════════════════════════════════
I/flutter (20894): The following NoSuchMethodError was thrown building NoteList(dirty, state: _NoteListState#e9138):
I/flutter (20894): The method 'initializeDatabase' was called on null.
I/flutter (20894): Receiver: null
I/flutter (20894): Tried calling: initializeDatabase()
Pls tell me solution..
Good video but for beginner its going to be little difficult to absorb. Instead of writing all methods like a big bang, you could have written code solution feature wise. Like first populate all task list via select query, then move on to delete button & delete query.. accordingly this way learns able to see the result of every method action.
Bro, have you completed this app ??
@@lakshandersagwal I felt this tutorial is pulling the motivation down.
I purchashed a udemy course and finished the sqflite in 2 hours. Happy to share code or link to the tutorial
@@kiranvysya yes bro, i would like to see, can u plz mail course link and code to me at lakshandersagwal@gmail.com
@@kiranvysya okay, i want
What is the solution of this Error: MissingPluginException(No implementation found for method getApplicationDocumentsDirectory on channel plugins.flutter.io/path_provider)
getting same problem
Awesome 👍👍👍👍👍
Saved notes not reflecting on the main page.Anyone faced the issue????even with the the github code>?
Hi, i have an issue and i hope you would be of help.
I added some other priorities to the _priorities variable ...
updated the updatePriorityAsInt() method and the getPriorityAsString() method, to reflect the new _priorities list.
I also updated the getPriorityColor() method in the note_list.dart file, to reflect these changes.
however, the drop down lists is only switching between High and Low priorities.
Please could you help ?
Kindly Ignore.
I fixed it.
Updated the set priority() method, inside the note.dart file in the model folder.
Please make a series on flutter with firebase
How can we create two database with relation one-many between them?
getNoteList, Can we use the Map to replace the for ... like that return noteMapList.map((mapNote) => Note.fromMapObject(mapNote));
While trying to save, I am getting an error message like this.
Please suggest.
[ERROR:flutter/lib/ui/ui_dart_state.cc(157)] Unhandled Exception: DatabaseException(table note_table has no column named date (code 1 SQLITE_ERROR): , while compiling: INSERT INTO note_table (title, description, priority, date) VALUES (?, NULL, ?, ?)) sql 'INSERT INTO note_table (title, description, priority, date) VALUES (?, NULL, ?, ?)' args [, 2, Feb 9, 2020]}
Hey, I just got the same error. :( Did you find a solution?
I can't view the insert in the list because it is not update. for solve it bug. you can insert in note_list.dart into NoteListState
@override
void initState() {
// TODO: implement initState
updateListView(); //forzar a que liste el elemento recién creado
super.initState();
}
When the app return to firstScreen the list would be update :)
Nice tutorial. I have few questions in it. If a item is deleted or added, is it a good approach to fetch all the items again. And I should be able fetch 10-10 items rather than fetching all items. It might create an issue if note list will be 1000 or more. Thanks
If u have large list items, then ListView.builder creates list items only for those, that are visible on screen. Similar to recycler view of android
I am getting this error. on a red screen
The getter 'firstName' was called on null.
Receiver: null
Tried calling: firstName
Can u help me by telling y i m getting this error n how can i solve it plzzzzzz
I learnt flutter watching ur video n m trying to develop an app for my clg project. Now I am stuck here from 3 days. plzz help me
Erroe in WillPopScope,
The function has return type Future ,but does not end with return statement .
file name: note_detail.dart [45,17].
Same error in my code and and code downloaded from github.
PLEASE HELP I AM GETTING THE SAME ERROR HOW CAN I FIX THIS?
@@not_arnav add a ' return;' to it, after moveToLastScreen
When i add or delete note object in delete view it directs to note_list view so here the note_list is not updated on the spot. But when i close and reopen the app, i can see the updated content in note_list. whats the problem here?
It´s posible that you have not in note_list.dart _delete method this : updateListView(); 7:00
So I am facing a problem if anybody can help.
For Some Reason,only the 'priority' instance variable of the Note class seems to not be getting inserted and updated in the database.
Rest all are working fine.
When I checked through debugPrint() the value of priority in 'NoteDetail ' class, it shows 'null'.
(As a result all my notes are by default of 'null' priority and of yellow background)
Using debugPrint(), I have checked, right upto just before the point where database is Inserted & Updated and I have got proper values for priority(ie 1or 2).
Only when I check it on retrieval, does it show 'null'.
I am using the same functions db.insert() and db.update() as @Smartherd for Insertion and Updation.
I also tried adding note.priority to whereArgs attribute in db.update(), but to no avail.
Can Anybody guess where the problem lies.
Thanks.
Hey bro, have you solved your problem ??
@@lakshandersagwal Nope. I tried certain things (for example using the rawInsert() function) but they resulted in different kind of errors(Run Time Exceptions).
I am only a beginner in Flutter so don't know much what else to try. 🤷♂️
@@AnkitTiwari-dw9er am also begineer bro, mind is fucked up, i also copied his code from github, it still shows so much errors.
void navigateToDetail(Note note, String title) async{
int? result = await Navigator.push(context, MaterialPageRoute(builder: (context){
return NoteDetail(note, title);
}));
if(result == true){
updateListView();
}
}
The following _CastError was thrown building NoteDetail(dirty, dependencies: [_InheritedTheme, _LocalizationsScope-[GlobalKey#44e71]], state: NoteDetailState#02499):
Null check operator used on a null value
plz give me this problems solution.
Hey everyone! Anyone can help me to fix this error
" could not get resolve com.android.tools.build:gradle: 3.3.0"
pls make a tutorial on how to add a note to each listview item. for example, the constitution of india. when you click an article you can either highlight or add notes no need for another screen just pop up
sure
@@smartherd thanks.
Why are we using break statement even after return in switch cases?
Just a safety 😁
Erroe in WillPopScope,
The function has return type Future ,but does not end with return statement .
file name: note_detail.dart [45,17].
Same error in my code and and code downloaded from github.
Please Reply.
mine also.R u fix this?plz send me how I fix this.
Use this
onWillPop: () {
return Future.value(true);
},
Error running Gradle:
ProcessException : process "c:\users\appname\ Android\gradlew.bat " excited abnormally:
> Configure project: sqflite
Iam getting this error continuously If anyone knows about this error ..pls tell how to solve.
Thanks in advance
got these error from the source code:
I/flutter ( 9786): ══╡ EXCEPTION CAUGHT BY WIDGETS LIBRARY ╞═══════════════════════════════════════════════════════════
I/flutter ( 9786): The following assertion was thrown building Builder(dirty):
I/flutter ( 9786): Looking up a deactivated widget's ancestor is unsafe.
I/flutter ( 9786): At this point the state of the widget's element tree is no longer stable. To safely refer to a
I/flutter ( 9786): widget's ancestor in its dispose() method, save a reference to the ancestor by calling
I/flutter ( 9786): inheritFromWidgetOfExactType() in the widget's didChangeDependencies() method.
I've got the same error here.. But thank you for the tutorial though.. real nice !
Did anyone got the solution for this issue??
how do i insert data?
Hi, can anyone let me know why buildcontext parameter been used in the _delete function (video timelog: 2:46)
To pass it to the snackbar
10 mins past and the code is not executed even once.. just code code code and code.. finally get lost ... Please seriously consider making tutorials that is bit sized, absorbed and relatable to learners.
This video lecture was too fast and need to watch again and again for understanding.. In this you perform all tasks well but did not teach as much as you can.
got to complex :'(
Only creating confusion
This is not for beginners
int result = await helper.deleteNote(note.id);
int result = await databaseHelper.deleteNote(note.id);
error: The argument type 'int' can't be assigned to the parameter type 'Note'. (argument_type_not_assignable at [database] lib\screens
ote_list.dart:116)
Check your method definition in class, and verify the method param for deleteNote, I think in your case it is Note and not id.
In database_helper.dart, you would have in the method deleteNote like this: Future deleteNote(int id).
it´s possible that you have in the parameter (Note note)
Not so well explained
this is very poor or say it tutty
this tutorial to too long for understand