Комментарии:
where is app:cardCornerRadius comes from?
Ответитьit gives me this error during the run time when i click on the button to strart the activity where the scroll layout is
E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.example.dietapp, PID: 21413
java.lang.RuntimeException: Unable to instantiate activity ComponentInfo{com.example.dietapp/com.example.dietapp.Peso}: java.lang.NullPointerException: Attempt to invoke virtual method 'android.content.pm.ApplicationInfo android.content.Context.getApplicationInfo()' on a null object reference
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3194)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3409)
at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:83)
at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:135)
at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:95)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2016)
at android.os.Handler.dispatchMessage(Handler.java:107)
at android.os.Looper.loop(Looper.java:214)
at android.app.ActivityThread.main(ActivityThread.java:7356)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:492)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:930)
Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'android.content.pm.ApplicationInfo android.content.Context.getApplicationInfo()' on a null object reference
at android.content.ContextWrapper.getApplicationInfo(ContextWrapper.java:163)
at android.view.ContextThemeWrapper.getTheme(ContextThemeWrapper.java:174)
at android.content.Context.obtainStyledAttributes(Context.java:738)
at androidx.appcompat.app.AppCompatDelegateImpl.createSubDecor(AppCompatDelegateImpl.java:922)
at androidx.appcompat.app.AppCompatDelegateImpl.ensureSubDecor(AppCompatDelegateImpl.java:889)
at androidx.appcompat.app.AppCompatDelegateImpl.findViewById(AppCompatDelegateImpl.java:691)
at androidx.appcompat.app.AppCompatActivity.findViewById(AppCompatActivity.java:264)
at com.example.dietapp.Peso.<init>(Peso.java:22)
at java.lang.Class.newInstance(Native Method)
at android.app.AppComponentFactory.instantiateActivity(AppComponentFactory.java:95)
at androidx.core.app.CoreComponentFactory.instantiateActivity(CoreComponentFactory.java:45)
at android.app.Instrumentation.newActivity(Instrumentation.java:1243)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3182)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3409)
at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:83)
at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:135)
at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:95)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2016)
at android.os.Handler.dispatchMessage(Handler.java:107)
at android.os.Looper.loop(Looper.java:214)
at android.app.ActivityThread.main(ActivityThread.java:7356)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:492)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:930)
Can I use constrain layout instead of relative layout?
ОтветитьUffff so Helpfull!!!!!!!!!!!! Thanks!!!!!!!!!
ОтветитьHow i can delete ConstraintLayout.LinearLayout object?
ОтветитьThis helps a lot. Thank you!
ОтветитьAt the end you don't show any app emulator, that's bad
Ответитьgreat job
it's problem that remove all data in container when close the app plz help me for the solve
Thank you so much! This is what I'm looking for
Ответитьhow to edit view
ОтветитьHi, thank you for the tutorial! can I ask if there is a way to delete all views at once with a button?
ОтветитьGreat video, How could I store what has been created using sharedprefs
ОтветитьI don't know why . But my code did not work. I write same as you. But my app crashed when i clicked on ok in dialog
ОтветитьHello, thank you so much for this great tutorial!
I'm wondering, if I want to have a number on the left side (starting with 1 to n) that is increasing with every card that I add, how could I accomplish that?
Este video es justo lo que buscaba
Bueno, casi pero suficiente para hacer lo que tengo en mente
how to save these added views...on closing the app and opening again my added views are deleted ....
Ответитьthanks but How can I clean up edittext after the first addition item
ОтветитьHi, thank u so much this is very helpful. I wish you could do a tutorial where it retrieves and stores the data from and to a SQLite database
ОтветитьCan we make those cards permanent on even when you restart your app
ОтветитьGreat job! but why did you create the AlertDialog dialog object? thx
Ответить