javascript - Jquery UI progressbar not animating with asp button -


I'm trying to use a jQuery UI progress bar which will show in a jQuery UI dialog when I have a ASP: Button .

has been declared as a button:

  & lt; Esp: Button ID = "Button 2" Runat = "Server" text = "TA © Laurers Charger" Reasoning WAITING = "False" OnClick = "Button 2 Black" On ClientClicks = "Javascript: Display Dialog ()" />   

Dialog has been declared as follow:

    

and finally javascript:

  & lt; Script type = "text / javascript" & gt; $ (Document) .ready (function () {$ ("# dialog"). Hide ();}); Function displayDialog () {$ ("# dialog") conversation (); $ ("# Progress bar") Progress Bar ({value: wrong}); $ ("# Dialog") show ().; } & Lt; / Script & gt;   

This works fine (since both are called onclick and the OnClientclick function). The code behind the code is executed correctly and also shows the dialog. Although the progress bar animation does not work (see the picture below).

Enter image details here

I do not understand that's what's up. I have tried not to use Show / Hide but property .css ("display", "none") and .css ("display", "block") $ ("# dialog") and the result is the same.

However, if I do not hide the dialog on $ (document). Always the animation works fine when I run it in script tags:

 < Code> $ (document) .ready (function () {$ ("# dialog"). Dialog (); $ ("# progressbar") progress bar ({value: false});});   

The dialog is displayed directly on the page when it loads:

Which is correct (I do not want to initially want it, but when you click on the button, but the progress bar still displays correctly it occurs).

You are finding this problem because you have your progress bar Dialog div

Error code:

  & lt; Div id = "dialog" title = "Attente de tà © là © Chargement" And lieutenant; P & gt; Le Fachière Est Choras de Para Paging, Le TA © Charges Develant Coders Saas Pe .. & Lt; / P & gt; & Lt; Div id = "progressbar" & gt; & Lt; / Div & gt; & Lt; / Div & gt;   

Any changes to the hidden elements will apply. So the better thing is to move the progress bar out of the dialog

> div.

Correct code:

  & lt; Div id = "dialog" title = "Attente de tà © là© chargement" And lieutenant; P & gt; Le Fachière Est Choras de Para Paging, Le TA © Charges Develant Coders Saas Pe .. & Lt; / P & gt; & Lt; / Div & gt; & Lt; Div id = "progressbar" & gt; & Lt; / Div & gt;   

Happy coding :)

Comments

Popular posts from this blog

c - Mpirun hangs when mpi send and recieve is put in a loop -

python - Apply coupon to a customer's subscription based on non-stripe related actions on the site -

java - Unable to get JDBC connection in Spring application to MySQL -