Flutter Local Notification Tutorial | Clock App (Episode-5)

  Рет қаралды 79,443

CodeX

CodeX

Күн бұрын

Пікірлер: 128
@CodeXdev
@CodeXdev 4 жыл бұрын
I know I am late in posting this video.. BUT this tutorial is going to be worth waiting. I have tried to explain Local Notification easiest way possible. Let me know what you think about this.. 😊
@vishaladhithya1553
@vishaladhithya1553 4 жыл бұрын
I'cant get the sound i have tried what you have i am testing in android it also didn't ask get any permisson in android phone
@CodeXdev
@CodeXdev 4 жыл бұрын
Try with downloading git sample from description...
@vishaladhithya1553
@vishaladhithya1553 4 жыл бұрын
the error was this PlatformException (PlatformException(INVALID_SOUND, The resource %s could not be found. Please make sure it has been added as a raw resource to your Android head project., null))
@CodeXdev
@CodeXdev 4 жыл бұрын
Error is self explanatory, your sound file is not found by Android app. Please go through example and place it in RAW folder under res. Make sure to name it correctly from you calling page
@amarmaharjan464
@amarmaharjan464 3 жыл бұрын
notification plugin seems to be updated. I hope you could make video on updated plugin
@barrachinasanernest
@barrachinasanernest 3 жыл бұрын
I've been one month trying to find someone that explains how to do that! Thank you!!
@CodeXdev
@CodeXdev 3 жыл бұрын
Glad I could help!
@muhammadnasreldin
@muhammadnasreldin 4 жыл бұрын
again , thank you .. you have a real supporter and a loyal student here
@CodeXdev
@CodeXdev 4 жыл бұрын
Thank you, that really means a lot😊
@ahmedadel756
@ahmedadel756 4 жыл бұрын
I was waiting for that ❤🙏
@KEvin-tv1io
@KEvin-tv1io 3 жыл бұрын
When you get the error at InitializationSettings() add android: and iOS: in front of the arguments like this: var initializationSettings = InitializationSettings(android:initializationSettingsAndroid, iOS: initializationSettingsIOS);
@psychology2251
@psychology2251 3 жыл бұрын
nice video great instructor
@KingLeoMessi
@KingLeoMessi 4 жыл бұрын
For sound error: place the two receiver code in last just before closing application tag if u got error for receiver tag
@jcgofredo2239
@jcgofredo2239 3 жыл бұрын
+1
@metamorphis7
@metamorphis7 3 жыл бұрын
instant like for the free github repo
@maheshperi19
@maheshperi19 4 жыл бұрын
Can we add buttons in notifications and action when click on it ?
@mlgen7
@mlgen7 4 жыл бұрын
This has been quite useful, would it be possible to show the required changes with the new version of the notification plugin?
@ahmedadel756
@ahmedadel756 4 жыл бұрын
Hey CodeX, i just bought u one coffee i know it is not much :) but just to keep you motivated Can't wait for your next clock Tutorial
@CodeXdev
@CodeXdev 4 жыл бұрын
*Hi @xWorld, appreciate your support.* 😊👍 New video in Clock App series is scheduled today... its about Local storage! 😍
@ahmedadel756
@ahmedadel756 4 жыл бұрын
@@CodeXdev thank you man
@CodeXdev
@CodeXdev 4 жыл бұрын
Still recording it.. if editing finishes will upload otherwise tomorrow 🥳
@ahmedadel756
@ahmedadel756 4 жыл бұрын
@@CodeXdev take your time, good luck bro 🥳😎
@crazy-man
@crazy-man 2 жыл бұрын
notification periodically will work ,even after reboot device on android? i know its works on ios
@leonardoaguirreramirez3553
@leonardoaguirreramirez3553 4 жыл бұрын
Excelente video. 👍🏿
@tennisbey
@tennisbey Жыл бұрын
3..2..1... that made me laughting hahaha thank you for the nice amazing video
@Pedro5antos_
@Pedro5antos_ 3 жыл бұрын
Thanks!
@CodeXdev
@CodeXdev 3 жыл бұрын
Welcome!
@binarysaiyan9389
@binarysaiyan9389 2 жыл бұрын
Ui looks awesome
@streamerx007
@streamerx007 4 жыл бұрын
Really needed in my upcoming project !
@CodeXdev
@CodeXdev 4 жыл бұрын
Cool, all my code on Git are open source. Feel free to utilise the best🥳
@Lokesh3152
@Lokesh3152 4 жыл бұрын
Thank you bro this helped alot of this Keep goin with more osm tuts
@CodeXdev
@CodeXdev 3 жыл бұрын
Glad it helped
@rufcode
@rufcode 9 күн бұрын
Do you have codes by any chance? I am not getting it.
@edimalok4707
@edimalok4707 3 жыл бұрын
@CodeX how did you do your notification icon because in this video your notification wasn't the one you set, it was still showing the flutter icon... I am asking this because i am facing this same problem
@CodeXdev
@CodeXdev 3 жыл бұрын
If you notice, I added custom icon for the Android config and not for iOS. Thats why in the iOS simulator its showing Flutter icon which is basically your app icon.
@revelmove
@revelmove 2 жыл бұрын
Wow that's great
@jackconceprio2273
@jackconceprio2273 3 жыл бұрын
If you want an icon for your App, set the icon size to 72x72 pixels, this is the recommended size.
@salihbalkis72
@salihbalkis72 3 жыл бұрын
if you get error on onDidReceiveLocalNotification, do it like following line. onDidReceiveLocalNotification: (int id, String? title, String? body, String? payload) async {}); Did you see the "Question Marks" on Strings?
@Elius0911
@Elius0911 2 жыл бұрын
Thank you very much!!!
@mateuszperyt7998
@mateuszperyt7998 2 жыл бұрын
life saver
@MehDiDao
@MehDiDao 4 жыл бұрын
can we use this plugin when the app is totally closed and not minimized ?
@CodeXdev
@CodeXdev 4 жыл бұрын
yes
@mirsaidefendi1661
@mirsaidefendi1661 4 жыл бұрын
@@CodeXdev can you make a tutorial about that topix please? for example, i have a DateTime birthday, and when that date comes i want to send a notifitacition, i tryed use background service but it effected battery usage badly,
@vitika2976
@vitika2976 3 жыл бұрын
@@mirsaidefendi1661 have you figured out how to do this?
@mirsaidefendi1661
@mirsaidefendi1661 3 жыл бұрын
@@vitika2976 yes, i used another background service plugin
@usuallyhungry657
@usuallyhungry657 2 жыл бұрын
for my project, i have created push notification with fcm and it's working great. Now i want to add custom sound to that push notification. Should i use local notification to achieve that? If so, can you help me with some information. I have tried a few tutorials ,and nothing worked.
@faisalmushtaq2287
@faisalmushtaq2287 4 жыл бұрын
have you tried the sound with android, please check
@memepage2333
@memepage2333 Жыл бұрын
bro i cant use that alarmmanger for scheduling notification now because of limitaitons in android , any alternatve
@cjt5570
@cjt5570 3 жыл бұрын
Hi bro, I managed to use FCM to send notification to the phone (Android), but the sound is not playing and no vibration. May I know how to config this or is there any way to override the default value? Thank you
@yashkhasgiwala7907
@yashkhasgiwala7907 4 жыл бұрын
keep up!
@achiawboateng7853
@achiawboateng7853 4 жыл бұрын
Thank you for this video. Can someone show me the steps to add notification sound in android flutter app
@mawaisadil2505
@mawaisadil2505 Жыл бұрын
Hi, I'm using Firebase with Flutter for Notification. Should we store the device token in the database only once when the app is started for the first time, or should we store it every time the app is opened? The reason behind this is that I want to trigger notifications from the backend (using Laravel) using the device token. So, what would be the best approach according to your experience? I'm developing my first app for production, and your opinion is very important to me.
@CodeXdev
@CodeXdev Жыл бұрын
Hello, generally we submit FCM device token to server on every login.
@ahmedadel756
@ahmedadel756 4 жыл бұрын
i am really learning a lot thank you
@CodeXdev
@CodeXdev 4 жыл бұрын
Great to hear that. Yes, will try to post early this week but yeah thats my schedule. Keep supporting 😊
@sidhantpatra9213
@sidhantpatra9213 4 жыл бұрын
How to get notifications even if device is restarted....
@justme8code
@justme8code 8 ай бұрын
Please my question is if I want to be able to schedule an alarm that would let's say notify me every Monday at a particular time how do I go about that
@CodeXdev
@CodeXdev 8 ай бұрын
Please check this pub.dev/packages/flutter_local_notifications#scheduling-a-notification
@peacefulmeditation9128
@peacefulmeditation9128 2 жыл бұрын
What would the code look like for the user of the app to select the alarm time from the app itself and not from the vscode? Or did I misunderstand the tutorial or do I need to watch a different tutorial the understand that part?
@CodeXdev
@CodeXdev 2 жыл бұрын
It’s actually series of videos, in every video I have discussed different concepts using same clock/alarm app example. So, this is not a full working app rather it is for demonstrating set of feature
@eminentwebsitesolutions465
@eminentwebsitesolutions465 4 жыл бұрын
* What went wrong: Execution failed for task ':app:processDebugResources'. > A failure occurred while executing com.android.build.gradle.internal.tasks.Workers$ActionFacade > Android resource linking failed F:\AndroidStudioProjects\mylife_app\android\app\src\main\AndroidManifest.xml:48:13-54:24: AAPT: error: unexpected element found in . F:\AndroidStudioProjects\mylife_app\android\app\src\main\AndroidManifest.xml:55:13-110: AAPT: error: unexpected element found in . Sir I am getting this error. Please help me!!
@manolos5242
@manolos5242 4 жыл бұрын
My Life & Company I get same error..., the manifest error, the receiver is out the activity
@suryameda6215
@suryameda6215 4 жыл бұрын
I get the same error. What is the fix?
@atifmughal3450
@atifmughal3450 2 жыл бұрын
Will this work when the application is closed (not minimized)?
@CodeXdev
@CodeXdev 2 жыл бұрын
Yes, at the time when I recorded it was working in force closed condition
@mkchannel1173
@mkchannel1173 4 жыл бұрын
If i want send notification to all user using mysql database how can do please?
@samsurya283
@samsurya283 4 жыл бұрын
Will the notification arrive even the app is closed?
@CodeXdev
@CodeXdev 4 жыл бұрын
Yes, it will! 👍🏼
@samsurya283
@samsurya283 4 жыл бұрын
@@CodeXdev Thanks a lot brother ❤
@katorimirido3568
@katorimirido3568 4 жыл бұрын
How to random body everyday in method showDailyAtTime?
@anjumohant8500
@anjumohant8500 3 жыл бұрын
Thank you
@saratmohan7327
@saratmohan7327 3 жыл бұрын
Hai CodeX I had referred your code and it doesn't receive any notification while setting time. One more thing can you please specify the notification to be received at regular intervals.Suppose now the time is 9 00 pm the time to be set at 10 pm. The notification required is while at 9 30pm the notification will be only 30 mins left and at 9 45 pm the notification will be only 15 mins left and at 10 pm no notification should be received.Can you please solve ASAP?
@sterrickunt7507
@sterrickunt7507 4 жыл бұрын
hey! Why have you not shown the part where you add the function to change time in alarm list item
@gapmuttanzania7356
@gapmuttanzania7356 Жыл бұрын
Hellow codex. i found a problem here when i build flutter apk and install the sound not ring. Please help me why not ring?
@RahulGupta-cz7of
@RahulGupta-cz7of 3 жыл бұрын
Does it work if the app is removed from the background?
@CodeXdev
@CodeXdev 3 жыл бұрын
Yes, it works
@SisirKumarPathy
@SisirKumarPathy 3 жыл бұрын
Will it also work if the app is not running at all e.g. the is not open yet?
@CodeXdev
@CodeXdev 3 жыл бұрын
Yes it will.. 👍🏼
@nabinkawan9298
@nabinkawan9298 3 жыл бұрын
@@CodeXdev but how to delete the scheduled alarm after the alarm task has been completed even when the app is not running (not active) sir.
@TheMifmex
@TheMifmex 3 жыл бұрын
When the apps in minimize or not active, is the notification still shown ?
@CodeXdev
@CodeXdev 3 жыл бұрын
Yes 👍🏼
@nilampathak7609
@nilampathak7609 4 жыл бұрын
There is no xcode option in IOS folder in my vscode
@kianu2010
@kianu2010 4 жыл бұрын
this is alarm but sound is stopped by touching notification how can i continuously play sound when touch the stop button in alarm app?
@sushantpagam7381
@sushantpagam7381 4 жыл бұрын
I am not able to play custom sound and also pop up are not showing up in lock screen and on screen also
@johnmichaeltorres1278
@johnmichaeltorres1278 2 жыл бұрын
Hello I can`t run my project This was the error What went wrong: Execution failed for task ':app:processDebugMainManifest'. > Manifest merger failed : android:exported needs to be explicitly specified for . Apps targeting Android 12 and higher are required to specify an explicit value for `android:exported` when the corresponding component has an intent filter defined.
@daily_dose_of_polls
@daily_dose_of_polls 3 жыл бұрын
hi, I tried it in android app,notifications are coming with default sound..custom sound is not working.i have added mp3 audio in res/raw.pls help me
@CodeXdev
@CodeXdev 3 жыл бұрын
You might need to check the intialization part inside main.dart
@beenashahi2315
@beenashahi2315 4 жыл бұрын
Is there any way to not launch the app on notification click?
@jakebrowning2373
@jakebrowning2373 4 жыл бұрын
why would you need that?
@sanjeevgupta8956
@sanjeevgupta8956 3 жыл бұрын
Also show the payload on the notification.
@codeforthought1883
@codeforthought1883 4 жыл бұрын
But what about notification from background?
@CodeXdev
@CodeXdev 4 жыл бұрын
It should work👍🏼
@poisonels8023
@poisonels8023 4 жыл бұрын
can you do video on cloud messaging?
@CodeXdev
@CodeXdev 4 жыл бұрын
Sure, when i will cover firebase that time I will cover it👍🏼
@faisalpheonix8800
@faisalpheonix8800 4 жыл бұрын
i am not getting the permission requests. please help
@CodeXdev
@CodeXdev 4 жыл бұрын
Please follow the Git source, it should work :)
@faisalpheonix8800
@faisalpheonix8800 4 жыл бұрын
@@CodeXdev i've tried but same results. tell me have you tried the project on android device??
@faresrayaaene7290
@faresrayaaene7290 3 жыл бұрын
The notification won't pop up why ?? How to solve it ??
@KanhaiyaKumarSingh-of9zk
@KanhaiyaKumarSingh-of9zk 3 жыл бұрын
It's not working in my project
@nileshbhakre7050
@nileshbhakre7050 4 жыл бұрын
Plz update your packages since schedule is deprecated to zoned schedule
@CodeXdev
@CodeXdev 3 жыл бұрын
I haven't worked on this project from a while, You can create a pull request on GitHub if you like.
@ahmedadel756
@ahmedadel756 4 жыл бұрын
Hello, i wish you could help me, i keep getting this error Execution failed for task ':app:processDebugResources'. > A failure occurred while executing com.android.build.gradle.internal.tasks.Workers$ActionFacade > Android resource linking failed
@CodeXdev
@CodeXdev 4 жыл бұрын
Hi, please check that you have all files as mentioned in code. WAV file and Notification Icon specifically...
@ahmedadel756
@ahmedadel756 4 жыл бұрын
@@CodeXdev thank you the problem is solved :)
@ahmedadel756
@ahmedadel756 4 жыл бұрын
@@CodeXdev you mentioned in the video, that when we kill the app we can't get a notification anymore. So is there anyway around to get a notification even if the app where killed?!
@CodeXdev
@CodeXdev 4 жыл бұрын
I mentioned that notification will not come when app is in foreground... ☺️ for other scenarios like minimised, closed or phone restarted it will work 👍
@bahtiyarcerit8878
@bahtiyarcerit8878 4 жыл бұрын
I dont understand that .. Please help me? Tried to send a platform message to Flutter, but FlutterJNI was detached from native C++. Could not send. Channel: plugins.flutter.io/firebase_database. Response ID: 0
@ahmedabdel-salam4409
@ahmedabdel-salam4409 4 жыл бұрын
what about remote notification?
@CodeXdev
@CodeXdev 4 жыл бұрын
That is even simpler, use FCM
@ahmedabdel-salam4409
@ahmedabdel-salam4409 4 жыл бұрын
@@CodeXdev more details please
@ahmedabdel-salam4409
@ahmedabdel-salam4409 4 жыл бұрын
@@CodeXdev i can not find good tutourial
@ezekielprabhu4161
@ezekielprabhu4161 4 жыл бұрын
Is this app functional?
@CodeXdev
@CodeXdev 4 жыл бұрын
Yes, going to complete this app in upcoming videos.
@09-tranthitham84
@09-tranthitham84 3 жыл бұрын
how can i turn off alarm?
@CodeXdev
@CodeXdev 3 жыл бұрын
You need to keep the ID's store and remove the schedule based on ID whenever you turn it off.
@hasnatakbar0170
@hasnatakbar0170 5 ай бұрын
can u help me in my code?
@CodeXdev
@CodeXdev 5 ай бұрын
Please book a slot here: ko-fi.com/afzalali15/commissions
@himanshumishra5975
@himanshumishra5975 4 жыл бұрын
How to handle this error Sir?? * What went wrong: Execution failed for task ':app:processDebugResources'. > A failure occurred while executing com.android.build.gradle.internal.tasks.Workers$ActionFacade > Android resource linking failed D:\COMPUTER SCIENCE\Flutter Apps\My Practice Apps\alarm_clock\android\Apps\alarm_clock\android\app\src\main\AndroidManifest.xml:43:18-48:29: AAPT: error: unexpected element found in . D:\COMPUTER SCIENCE\Flutter Apps\My Practice Apps\alarm_clock\android\Apps\alarm_clock\android\app\src\main\AndroidManifest.xml:49:18-115: AAPT: error: unexpected element found in . * Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights. * Get more help at help.gradle.org
@CodeXdev
@CodeXdev 4 жыл бұрын
your is wrongly placed.. it should go inside tag and not inside Refer manifest from Git Source shared in description.
@himanshumishra5975
@himanshumishra5975 4 жыл бұрын
@@CodeXdev Now it has been solved Sir
@erikaszabo1439
@erikaszabo1439 4 жыл бұрын
@@CodeXdev so you did wrongly in your video? pls at least mention it
@CodeXdev
@CodeXdev 4 жыл бұрын
Yes, i made mistake unknowingly.. i realised only after few people reported. Corrected my git source as well for Android issue🥳
@himanshumishra5975
@himanshumishra5975 4 жыл бұрын
I am facing this error [ERROR:flutter/lib/ui/ui_dart_state.cc(166)] Unhandled Exception: setState() called after dispose(): _ClockViewState#60110(lifecycle state: defunct, not mounted) E/flutter (25227): This error happens if you call setState() on a State object for a widget that no longer appears in the widget tree (e.g., whose parent widget no longer includes the widget in its build). This error can occur when code calls setState() from a timer or an animation callback. E/flutter (25227): The preferred solution is to cancel the timer or stop listening to the animation in the dispose() callback. Another solution is to check the "mounted" property of this object before calling setState() to ensure the object is still in the tree. E/flutter (25227): This error might indicate a memory leak if setState() is being called because another object is retaining a reference to this State object after it has been removed from the tree. To avoid memory leaks, consider breaking the reference to this object during dispose(). And also I am not getting Notifications. Please help me to solve this error
@suryameda6215
@suryameda6215 4 жыл бұрын
I am facing the same setstate errors
@suryameda6215
@suryameda6215 4 жыл бұрын
I tried adding this command If(! mounted) return; Above the setState and it kind of solved.
@saratmohan7327
@saratmohan7327 3 жыл бұрын
In my point whether it is correct or not before the packages at particular name.dart the statement is //@dart=2.9
Flutter Custom Painter Tutorial || Clock App (Episode-1)
16:31
“Don’t stop the chances.”
00:44
ISSEI / いっせい
Рет қаралды 62 МЛН
Try this prank with your friends 😂 @karina-kola
00:18
Andrey Grechka
Рет қаралды 9 МЛН
Cat mode and a glass of water #family #humor #fun
00:22
Kotiki_Z
Рет қаралды 42 МЛН
Tuna 🍣 ​⁠@patrickzeinali ​⁠@ChefRush
00:48
albert_cancook
Рет қаралды 148 МЛН
📱Android Push Notifications • Flutter x Firebase Tutorial
12:39
Flutter Animation in 5 Minutes
5:01
Fun with Flutter
Рет қаралды 176 М.
OneSignal Notifications in Flutter Made Easy | Step-by-Step Tutorial
11:11
Most overpowered way to build mobile apps?
8:33
Beyond Fireship
Рет қаралды 879 М.
Top 30 Flutter Tips and Tricks
6:50
Flutter Mapp
Рет қаралды 583 М.
“Don’t stop the chances.”
00:44
ISSEI / いっせい
Рет қаралды 62 МЛН