Learn to develop mobile apps using Flutter for both Android and iOS
smartherd / flutter-demos Goto Github PK
View Code? Open in Web Editor NEWLearn to develop mobile apps using Flutter for both Android and iOS
Learn to develop mobile apps using Flutter for both Android and iOS
you have made it sooo much complex pleas emake it bare bones simple like a basic todo app with very very few but easy code
The list view does not update when added a new note. but it updates when the app is closed and opened again
I keep getting the following exception when I try to save the note to the database:
E/flutter (18356): [ERROR:flutter/lib/ui/ui_dart_state.cc(157)] Unhandled Exception: DatabaseException(table note_table has no column named description (code 1 SQLITE_ERROR[1]): , while compiling: INSERT INTO note_table (title, description, priority, date) VALUES (?, ?, ?, ?)) sql 'INSERT INTO note_table (title, description, priority, date) VALUES (?, ?, ?, ?)' args [frdf, hrdgy, 2, Mar 27, 2020]}
Hi, thanks for the wonderful tutorial.
I keep getting the error looking Up a deactivated widgets ancestor is unsafe. At this point the state of the element tree is no longer stable to safely refer to a widget's ancestor in it's dispose() method, save a reference to the ancestor by calling InheritFromWidgetOfExactType() in the widget's didChangeDependancies() method
This occurs during clicking save when creating a new note and it tries to pop back to the notelist view
The following NoSuchMethodError was thrown building NoteList(dirty, state: _NoteListState#e3e90):
The method 'initializeDatabase' was called on null.
Receiver: null
Tried calling: initializeDatabase()
The relevant error-causing widget was:
NoteList file:///E:/FlutterWorkspace/flutterfundoo/lib/services/authservice.dart:15:20
When the exception was thrown, this was the stack:
#0 Object.noSuchMethod (dart:core-patch/object_patch.dart:54:5)
#1 _NoteListState.updateListView (package:flutterfundoo/activated/note_list.dart:185:54)
#2 _NoteListState.build (package:flutterfundoo/activated/note_list.dart:23:7)
#3 StatefulElement.build (package:flutter/src/widgets/framework.dart:4612:27)
#4 ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4495:15)
I am getting this error:
'NoteDetail' isn't defined for the class 'NoteListState'.
The function where this error originates is this one:
void navigateToDetail(String title) {
Navigator.push(context, MaterialPageRoute(builder: (context) {
return NoteDetail(title);
}));
}
}
how do i create a database inside the code instead of generate it from a keyboard input?
https://github.com/smartherd/Flutter-Demos/blob/master/lib/utils/database_helper.dart
`class DatabaseHelper
{
DatabaseHelper _databaseHelper;
Database _database;
String noteTable = 'note_table';
String colId = 'id';
String colTitle = 'title';
String colDescreption = 'descreption';
String colDate = 'date';
String colPriorety = 'priorety';
DatabaseHelper._createInstance();
factory DatabaseHelper(){
if (_databaseHelper == null){
_databaseHelper = DatabaseHelper._createInstance();
}
return _databaseHelper;
}
}`
in the factory constructor, i get this error below.
{
"resource": "[......]/flutterapp/lib/utils/database_helper.dart",
"owner": "dart",
"code": "instance_member_access_from_factory",
"severity": 8,
"message": "Instance members can't be accessed from a factory constructor.",
"source": "dart",
"startLineNumber": 22,
"startColumn": 9,
"endLineNumber": 22,
"endColumn": 24,
"tags": []
}
what does this mean? and how to fix it?
void moveToLastScreen() {
Navigator.pop(context, true);
}
═╡ EXCEPTION CAUGHT BY GESTURE ╞═
type 'bool' is not a subtype of type 'int' of 'result'
Some plugins are not compatible with androidx
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.