Sweet Alert crash when application is runningIs there a way to run Python on Android?App Crash While Clicking Button When EditText is NullAndroid problems with onClick()Could not execute method for android:on remind meError java.lang.NoClassDefFoundError: org.firebirdsql.jdbc.FBDataSource on AndroidApp keeps crashing. Any ideas?Android: Implement Select all checkbox in gridview with checkbox and imageviewi have an error in column application can't get data from some column in table androidnull object reference on getView Method(Android Studio) ArrayList Size makes error when I want to check it

Improving Sati-Sampajañña (situative wisdom)

Can 'sudo apt-get remove [write]' destroy my Ubuntu?

We are two immediate neighbors who forged our own powers to form concatenated relationship. Who are we?

Is ‘despite that’ right?

Is there a need for better software for writers?

I might have messed up in the 'Future Work' section of my thesis

Is it bad writing or bad story telling if first person narrative contains more information than the narrator knows?

How can a viral infection spread throughout the body without being noticed?

Is it a Munchausen Number?

What is the criteria of choosing a given pin pattern in ICs?

How is CoreiX like Corei5, i7 is related to Haswell, Ivy Bridge?

How to compare d20+x with advantage to d20+y without advantage (x < y)

What is the name of meteoroids which hit Moon, Mars, or pretty much anything that isn’t the Earth?

Different problems with tabularx

Why does increasing the sampling rate make implementing an anti-aliasing filter easier?

What's the "magic similar to the Knock spell" referenced in the Dungeon of the Mad Mage adventure?

Windows OS quantum vs. SQL OS Quantum

Any suggestions on how to make this table prettier and suggestions on whether it's better to make it fit in 1 or 2 columns

Which other programming languages apart from Python and predecessor are out there using indentation to define code blocks?

How to make a language evolve quickly?

What does formal training in a field mean?

Two researchers want to work on the same extension to my paper. Who to help?

Why is it wrong to *implement* myself a known, published, widely believed to be secure crypto algorithm?

Electric kick drum pedal starts oscillating in such a way that it does not register hits



Sweet Alert crash when application is running


Is there a way to run Python on Android?App Crash While Clicking Button When EditText is NullAndroid problems with onClick()Could not execute method for android:on remind meError java.lang.NoClassDefFoundError: org.firebirdsql.jdbc.FBDataSource on AndroidApp keeps crashing. Any ideas?Android: Implement Select all checkbox in gridview with checkbox and imageviewi have an error in column application can't get data from some column in table androidnull object reference on getView Method(Android Studio) ArrayList Size makes error when I want to check it






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty height:90px;width:728px;box-sizing:border-box;








0















I want to use sweet alert for my app so I'm creating a demo based on turtorial. At first I crash into 'android:icon' problem but I managed to fixxed it, now my app crash whenever SweetAlert being used. I have try xmlns:tools="http://schemas.android.com/tools", tools:replace="android:icon" or downgrade sweet alert to 1.2 version but it still crash. Here are my code.



activity_main.xml



<Button
android:id="@+id/btnButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="add new"
android:layout_gravity="center"
/>


MainActivity.java



public class MainActivity extends AppCompatActivity 
Button b;
@Override
protected void onCreate(Bundle savedInstanceState)
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
b = (Button) findViewById(R.id.btnButton);
b.setOnClickListener(new View.OnClickListener()
@Override
public void onClick(View v)
new SweetAlertDialog(MainActivity.this).setTitleText("Hello Man!")
.setContentText("Welcome").show();

);




My Error



E/AndroidRuntime: FATAL EXCEPTION: main
Process: day10.silverboy.sweetalert, PID: 3135
java.lang.RuntimeException: Unknown animation name: cn.pedant.SweetAlert.Rotate3dAnimation error:null
at cn.pedant.SweetAlert.OptAnimationLoader.createAnimationFromXml(OptAnimationLoader.java:77)
at cn.pedant.SweetAlert.OptAnimationLoader.createAnimationFromXml(OptAnimationLoader.java:64)
at cn.pedant.SweetAlert.OptAnimationLoader.createAnimationFromXml(OptAnimationLoader.java:41)
at cn.pedant.SweetAlert.OptAnimationLoader.loadAnimation(OptAnimationLoader.java:22)
at cn.pedant.SweetAlert.SweetAlertDialog.<init>(SweetAlertDialog.java:73)
at cn.pedant.SweetAlert.SweetAlertDialog.<init>(SweetAlertDialog.java:65)
at day10.silverboy.sweetalert.MainActivity$1.onClick(MainActivity.java:20)
at android.view.View.performClick(View.java:4780)
at android.view.View$PerformClick.run(View.java:19866)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:135)
at android.app.ActivityThread.main(ActivityThread.java:5254)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:903)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:698)









share|improve this question



















  • 1





    add you SweetAlertDialog class

    – Tamir Abutbul
    Mar 23 at 9:40











  • Sorry but I don't get your point. Can you explain specific for me what I need to do? It doesn't alert error for me when I adding it into MainActivity so surely there's SweetAlert.

    – FaizEming
    Mar 23 at 9:51












  • add the code of your SweetAlertDialog class

    – Tamir Abutbul
    Mar 23 at 9:52











  • SweetAlertDialog come from pedant dependencies that I compile in Gradle. What and why do I need to add anything?

    – FaizEming
    Mar 23 at 10:05












  • And what library that would be?

    – Tamir Abutbul
    Mar 23 at 10:10

















0















I want to use sweet alert for my app so I'm creating a demo based on turtorial. At first I crash into 'android:icon' problem but I managed to fixxed it, now my app crash whenever SweetAlert being used. I have try xmlns:tools="http://schemas.android.com/tools", tools:replace="android:icon" or downgrade sweet alert to 1.2 version but it still crash. Here are my code.



activity_main.xml



<Button
android:id="@+id/btnButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="add new"
android:layout_gravity="center"
/>


MainActivity.java



public class MainActivity extends AppCompatActivity 
Button b;
@Override
protected void onCreate(Bundle savedInstanceState)
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
b = (Button) findViewById(R.id.btnButton);
b.setOnClickListener(new View.OnClickListener()
@Override
public void onClick(View v)
new SweetAlertDialog(MainActivity.this).setTitleText("Hello Man!")
.setContentText("Welcome").show();

);




My Error



E/AndroidRuntime: FATAL EXCEPTION: main
Process: day10.silverboy.sweetalert, PID: 3135
java.lang.RuntimeException: Unknown animation name: cn.pedant.SweetAlert.Rotate3dAnimation error:null
at cn.pedant.SweetAlert.OptAnimationLoader.createAnimationFromXml(OptAnimationLoader.java:77)
at cn.pedant.SweetAlert.OptAnimationLoader.createAnimationFromXml(OptAnimationLoader.java:64)
at cn.pedant.SweetAlert.OptAnimationLoader.createAnimationFromXml(OptAnimationLoader.java:41)
at cn.pedant.SweetAlert.OptAnimationLoader.loadAnimation(OptAnimationLoader.java:22)
at cn.pedant.SweetAlert.SweetAlertDialog.<init>(SweetAlertDialog.java:73)
at cn.pedant.SweetAlert.SweetAlertDialog.<init>(SweetAlertDialog.java:65)
at day10.silverboy.sweetalert.MainActivity$1.onClick(MainActivity.java:20)
at android.view.View.performClick(View.java:4780)
at android.view.View$PerformClick.run(View.java:19866)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:135)
at android.app.ActivityThread.main(ActivityThread.java:5254)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:903)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:698)









share|improve this question



















  • 1





    add you SweetAlertDialog class

    – Tamir Abutbul
    Mar 23 at 9:40











  • Sorry but I don't get your point. Can you explain specific for me what I need to do? It doesn't alert error for me when I adding it into MainActivity so surely there's SweetAlert.

    – FaizEming
    Mar 23 at 9:51












  • add the code of your SweetAlertDialog class

    – Tamir Abutbul
    Mar 23 at 9:52











  • SweetAlertDialog come from pedant dependencies that I compile in Gradle. What and why do I need to add anything?

    – FaizEming
    Mar 23 at 10:05












  • And what library that would be?

    – Tamir Abutbul
    Mar 23 at 10:10













0












0








0








I want to use sweet alert for my app so I'm creating a demo based on turtorial. At first I crash into 'android:icon' problem but I managed to fixxed it, now my app crash whenever SweetAlert being used. I have try xmlns:tools="http://schemas.android.com/tools", tools:replace="android:icon" or downgrade sweet alert to 1.2 version but it still crash. Here are my code.



activity_main.xml



<Button
android:id="@+id/btnButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="add new"
android:layout_gravity="center"
/>


MainActivity.java



public class MainActivity extends AppCompatActivity 
Button b;
@Override
protected void onCreate(Bundle savedInstanceState)
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
b = (Button) findViewById(R.id.btnButton);
b.setOnClickListener(new View.OnClickListener()
@Override
public void onClick(View v)
new SweetAlertDialog(MainActivity.this).setTitleText("Hello Man!")
.setContentText("Welcome").show();

);




My Error



E/AndroidRuntime: FATAL EXCEPTION: main
Process: day10.silverboy.sweetalert, PID: 3135
java.lang.RuntimeException: Unknown animation name: cn.pedant.SweetAlert.Rotate3dAnimation error:null
at cn.pedant.SweetAlert.OptAnimationLoader.createAnimationFromXml(OptAnimationLoader.java:77)
at cn.pedant.SweetAlert.OptAnimationLoader.createAnimationFromXml(OptAnimationLoader.java:64)
at cn.pedant.SweetAlert.OptAnimationLoader.createAnimationFromXml(OptAnimationLoader.java:41)
at cn.pedant.SweetAlert.OptAnimationLoader.loadAnimation(OptAnimationLoader.java:22)
at cn.pedant.SweetAlert.SweetAlertDialog.<init>(SweetAlertDialog.java:73)
at cn.pedant.SweetAlert.SweetAlertDialog.<init>(SweetAlertDialog.java:65)
at day10.silverboy.sweetalert.MainActivity$1.onClick(MainActivity.java:20)
at android.view.View.performClick(View.java:4780)
at android.view.View$PerformClick.run(View.java:19866)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:135)
at android.app.ActivityThread.main(ActivityThread.java:5254)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:903)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:698)









share|improve this question
















I want to use sweet alert for my app so I'm creating a demo based on turtorial. At first I crash into 'android:icon' problem but I managed to fixxed it, now my app crash whenever SweetAlert being used. I have try xmlns:tools="http://schemas.android.com/tools", tools:replace="android:icon" or downgrade sweet alert to 1.2 version but it still crash. Here are my code.



activity_main.xml



<Button
android:id="@+id/btnButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="add new"
android:layout_gravity="center"
/>


MainActivity.java



public class MainActivity extends AppCompatActivity 
Button b;
@Override
protected void onCreate(Bundle savedInstanceState)
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
b = (Button) findViewById(R.id.btnButton);
b.setOnClickListener(new View.OnClickListener()
@Override
public void onClick(View v)
new SweetAlertDialog(MainActivity.this).setTitleText("Hello Man!")
.setContentText("Welcome").show();

);




My Error



E/AndroidRuntime: FATAL EXCEPTION: main
Process: day10.silverboy.sweetalert, PID: 3135
java.lang.RuntimeException: Unknown animation name: cn.pedant.SweetAlert.Rotate3dAnimation error:null
at cn.pedant.SweetAlert.OptAnimationLoader.createAnimationFromXml(OptAnimationLoader.java:77)
at cn.pedant.SweetAlert.OptAnimationLoader.createAnimationFromXml(OptAnimationLoader.java:64)
at cn.pedant.SweetAlert.OptAnimationLoader.createAnimationFromXml(OptAnimationLoader.java:41)
at cn.pedant.SweetAlert.OptAnimationLoader.loadAnimation(OptAnimationLoader.java:22)
at cn.pedant.SweetAlert.SweetAlertDialog.<init>(SweetAlertDialog.java:73)
at cn.pedant.SweetAlert.SweetAlertDialog.<init>(SweetAlertDialog.java:65)
at day10.silverboy.sweetalert.MainActivity$1.onClick(MainActivity.java:20)
at android.view.View.performClick(View.java:4780)
at android.view.View$PerformClick.run(View.java:19866)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:135)
at android.app.ActivityThread.main(ActivityThread.java:5254)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:903)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:698)






android sweetalert






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Mar 23 at 10:17









Masum

484520




484520










asked Mar 23 at 9:35









FaizEmingFaizEming

244




244







  • 1





    add you SweetAlertDialog class

    – Tamir Abutbul
    Mar 23 at 9:40











  • Sorry but I don't get your point. Can you explain specific for me what I need to do? It doesn't alert error for me when I adding it into MainActivity so surely there's SweetAlert.

    – FaizEming
    Mar 23 at 9:51












  • add the code of your SweetAlertDialog class

    – Tamir Abutbul
    Mar 23 at 9:52











  • SweetAlertDialog come from pedant dependencies that I compile in Gradle. What and why do I need to add anything?

    – FaizEming
    Mar 23 at 10:05












  • And what library that would be?

    – Tamir Abutbul
    Mar 23 at 10:10












  • 1





    add you SweetAlertDialog class

    – Tamir Abutbul
    Mar 23 at 9:40











  • Sorry but I don't get your point. Can you explain specific for me what I need to do? It doesn't alert error for me when I adding it into MainActivity so surely there's SweetAlert.

    – FaizEming
    Mar 23 at 9:51












  • add the code of your SweetAlertDialog class

    – Tamir Abutbul
    Mar 23 at 9:52











  • SweetAlertDialog come from pedant dependencies that I compile in Gradle. What and why do I need to add anything?

    – FaizEming
    Mar 23 at 10:05












  • And what library that would be?

    – Tamir Abutbul
    Mar 23 at 10:10







1




1





add you SweetAlertDialog class

– Tamir Abutbul
Mar 23 at 9:40





add you SweetAlertDialog class

– Tamir Abutbul
Mar 23 at 9:40













Sorry but I don't get your point. Can you explain specific for me what I need to do? It doesn't alert error for me when I adding it into MainActivity so surely there's SweetAlert.

– FaizEming
Mar 23 at 9:51






Sorry but I don't get your point. Can you explain specific for me what I need to do? It doesn't alert error for me when I adding it into MainActivity so surely there's SweetAlert.

– FaizEming
Mar 23 at 9:51














add the code of your SweetAlertDialog class

– Tamir Abutbul
Mar 23 at 9:52





add the code of your SweetAlertDialog class

– Tamir Abutbul
Mar 23 at 9:52













SweetAlertDialog come from pedant dependencies that I compile in Gradle. What and why do I need to add anything?

– FaizEming
Mar 23 at 10:05






SweetAlertDialog come from pedant dependencies that I compile in Gradle. What and why do I need to add anything?

– FaizEming
Mar 23 at 10:05














And what library that would be?

– Tamir Abutbul
Mar 23 at 10:10





And what library that would be?

– Tamir Abutbul
Mar 23 at 10:10












1 Answer
1






active

oldest

votes


















0














SweetAlertDialog pDialog = new SweetAlertDialog(this, 
SweetAlertDialog.PROGRESS_TYPE);
pDialog.getProgressHelper().setBarColor(Color.parseColor("#A5DC86"));
pDialog.setTitleText("Loading");
pDialog.setCancelable(false);

b.setOnClickListener(new View.OnClickListener()
@Override
public void onClick(View v)
pDialog.show();`enter code here`

);





share|improve this answer























    Your Answer






    StackExchange.ifUsing("editor", function ()
    StackExchange.using("externalEditor", function ()
    StackExchange.using("snippets", function ()
    StackExchange.snippets.init();
    );
    );
    , "code-snippets");

    StackExchange.ready(function()
    var channelOptions =
    tags: "".split(" "),
    id: "1"
    ;
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function()
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled)
    StackExchange.using("snippets", function()
    createEditor();
    );

    else
    createEditor();

    );

    function createEditor()
    StackExchange.prepareEditor(
    heartbeatType: 'answer',
    autoActivateHeartbeat: false,
    convertImagesToLinks: true,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: 10,
    bindNavPrevention: true,
    postfix: "",
    imageUploader:
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    ,
    onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    );



    );













    draft saved

    draft discarded


















    StackExchange.ready(
    function ()
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55312409%2fsweet-alert-crash-when-application-is-running%23new-answer', 'question_page');

    );

    Post as a guest















    Required, but never shown

























    1 Answer
    1






    active

    oldest

    votes








    1 Answer
    1






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes









    0














    SweetAlertDialog pDialog = new SweetAlertDialog(this, 
    SweetAlertDialog.PROGRESS_TYPE);
    pDialog.getProgressHelper().setBarColor(Color.parseColor("#A5DC86"));
    pDialog.setTitleText("Loading");
    pDialog.setCancelable(false);

    b.setOnClickListener(new View.OnClickListener()
    @Override
    public void onClick(View v)
    pDialog.show();`enter code here`

    );





    share|improve this answer



























      0














      SweetAlertDialog pDialog = new SweetAlertDialog(this, 
      SweetAlertDialog.PROGRESS_TYPE);
      pDialog.getProgressHelper().setBarColor(Color.parseColor("#A5DC86"));
      pDialog.setTitleText("Loading");
      pDialog.setCancelable(false);

      b.setOnClickListener(new View.OnClickListener()
      @Override
      public void onClick(View v)
      pDialog.show();`enter code here`

      );





      share|improve this answer

























        0












        0








        0







        SweetAlertDialog pDialog = new SweetAlertDialog(this, 
        SweetAlertDialog.PROGRESS_TYPE);
        pDialog.getProgressHelper().setBarColor(Color.parseColor("#A5DC86"));
        pDialog.setTitleText("Loading");
        pDialog.setCancelable(false);

        b.setOnClickListener(new View.OnClickListener()
        @Override
        public void onClick(View v)
        pDialog.show();`enter code here`

        );





        share|improve this answer













        SweetAlertDialog pDialog = new SweetAlertDialog(this, 
        SweetAlertDialog.PROGRESS_TYPE);
        pDialog.getProgressHelper().setBarColor(Color.parseColor("#A5DC86"));
        pDialog.setTitleText("Loading");
        pDialog.setCancelable(false);

        b.setOnClickListener(new View.OnClickListener()
        @Override
        public void onClick(View v)
        pDialog.show();`enter code here`

        );






        share|improve this answer












        share|improve this answer



        share|improve this answer










        answered Mar 23 at 10:58









        Raguram GRaguram G

        11




        11





























            draft saved

            draft discarded
















































            Thanks for contributing an answer to Stack Overflow!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid


            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.

            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55312409%2fsweet-alert-crash-when-application-is-running%23new-answer', 'question_page');

            );

            Post as a guest















            Required, but never shown





















































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown

































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown







            Popular posts from this blog

            1973년 목차 사건 문화 탄생 사망 노벨상 달력 둘러보기 메뉴

            SQL error code 1064 with creating Laravel foreign keysForeign key constraints: When to use ON UPDATE and ON DELETEDropping column with foreign key Laravel error: General error: 1025 Error on renameLaravel SQL Can't create tableLaravel Migration foreign key errorLaravel php artisan migrate:refresh giving a syntax errorSQLSTATE[42S01]: Base table or view already exists or Base table or view already exists: 1050 Tableerror in migrating laravel file to xampp serverSyntax error or access violation: 1064:syntax to use near 'unsigned not null, modelName varchar(191) not null, title varchar(191) not nLaravel cannot create new table field in mysqlLaravel 5.7:Last migration creates table but is not registered in the migration table

            155 수학 과학 기타 둘러보기 메뉴eh추가해eh문서를 완성해