+ 3

What can i do to get the functions starte, starts, startp executed?

here is the code https://code.sololearn.com/W3w3jEAfqk69/?ref=app

22nd Jul 2017, 2:08 PM
_Retr0/-
_Retr0/- - avatar
11 Answers
+ 4
What I would do from your code, was to handle this behaviour inside the startx() functions, handling setInterval() start/stop inside it: https://code.sololearn.com/W2JNtcjmHXP2/?ref=app ... but second improvement I would do immediatly next if not before, was to factorize the code, so I have only one function/object reused for any instances of couple progress/button ;)
22nd Jul 2017, 4:01 PM
visph
visph - avatar
+ 9
That functions are inserted inside a setInterval method, the setInterval method is inserted inside three different functions, so... just call them: stops(); stope(); stopp(); Tip: remove the console.log method. :3
22nd Jul 2017, 2:14 PM
Maz
Maz - avatar
+ 3
By calling them ^^ When need you execute them? What's the purpose of your code? Provide at least enough informations to be helped! ;P
22nd Jul 2017, 2:14 PM
visph
visph - avatar
+ 3
They are commented in your actual code ^^
22nd Jul 2017, 3:10 PM
visph
visph - avatar
+ 3
23rd Jul 2017, 2:32 AM
visph
visph - avatar
+ 2
Inside your startx() functions, you have this kind of code: var vals = document.getElementById("ps").value = val3++; That's not valid... What's your purpose? You doesn't need the var vars assignement: this will declare a local variable but you doesn't use it as you end function right there ^^ replace each of these lines, by just: document.getElementById("ps").value = val3++; Maybe it will be enpugh to solve your problem ;)
22nd Jul 2017, 3:17 PM
visph
visph - avatar
+ 2
(This works, if you uncomment too the calls to startx() functions ;P)
22nd Jul 2017, 3:19 PM
visph
visph - avatar
+ 1
I 'uncommented' them and they r still not working😬
22nd Jul 2017, 3:12 PM
_Retr0/-
_Retr0/- - avatar
+ 1
i would release my code soon now, thanks to you 👍👍👍👍👍
22nd Jul 2017, 4:04 PM
_Retr0/-
_Retr0/- - avatar
0
I have called them in the ef, sf, and of functions but they r still not getting executed 😖
22nd Jul 2017, 3:09 PM
_Retr0/-
_Retr0/- - avatar
0
still cannot get it started 😰 and if I uncomment starx functions then the progress bar works but they only run if u click multiple times. I need to make it so that if u click on a button it's progress bar starts loading and u if u click the other button the rest 2 progress bar should stop and only the respective button's progress bar should run. hope u made it clear to u 🙃
22nd Jul 2017, 3:47 PM
_Retr0/-
_Retr0/- - avatar