How to hide progressbar in Android?
up vote
7
down vote
favorite
I added a progressbar to my app but I want to hide it after some doing some action,
I used hide()
, dismiss()
and cancel()
... but none of them work?
How can I hide the progressbar?
android visibility android-progressbar
add a comment |
up vote
7
down vote
favorite
I added a progressbar to my app but I want to hide it after some doing some action,
I used hide()
, dismiss()
and cancel()
... but none of them work?
How can I hide the progressbar?
android visibility android-progressbar
add a comment |
up vote
7
down vote
favorite
up vote
7
down vote
favorite
I added a progressbar to my app but I want to hide it after some doing some action,
I used hide()
, dismiss()
and cancel()
... but none of them work?
How can I hide the progressbar?
android visibility android-progressbar
I added a progressbar to my app but I want to hide it after some doing some action,
I used hide()
, dismiss()
and cancel()
... but none of them work?
How can I hide the progressbar?
android visibility android-progressbar
android visibility android-progressbar
edited Aug 19 '16 at 6:50
onexf
1,63611429
1,63611429
asked Jan 17 '11 at 21:15
Adham
23.4k85202317
23.4k85202317
add a comment |
add a comment |
4 Answers
4
active
oldest
votes
up vote
23
down vote
ProgressBar.setVisibility(View.INVISIBLE)
should be enough.
Edit: fixed typo.
what a bout Dialog ?! how we can do that ?? it don't have setVisibilty()
– Adham
Jan 17 '11 at 21:46
Do you have a ProgressDialog, or a ProgressBar??
– Aman Alam
Jan 18 '11 at 7:56
2
you have a typo: should be setVisibil >i< ty
– alex
Apr 27 '12 at 12:21
add a comment |
up vote
4
down vote
"all of them are work", that sounds like it means that they work? But then why the question?
I'd say: get the view, en do
myView.setVisibility(View.GONE)
I'm sorry . they aren't .. i edited it :)
– Adham
Jan 17 '11 at 21:36
but I assume setVisibility does?
– Nanne
Jan 18 '11 at 7:43
it is not working....
– hharry
Jul 26 '13 at 6:03
add a comment |
up vote
3
down vote
ProgressBar progressBar = (ProgressBar) findViewById(R.id.progressBar);
progressBar.setVisibility(0); --visible
progressBar.setVisibility(4); --invisible
progressBar.setVisibility(8); --gone (like dismiss)
14
Why notprogressBar.setVisibility(View.Visible);
instead of using these magic numbers?
– Rafi Kamal
Jun 19 '14 at 14:44
add a comment |
up vote
1
down vote
when you want to show it
progressBar.visibility = View.VISIBLE
when you want to hide it
1 progressBar.visibility = View.GONE
2 progressBar.visibility = View.INVISIBLE
add a comment |
4 Answers
4
active
oldest
votes
4 Answers
4
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
23
down vote
ProgressBar.setVisibility(View.INVISIBLE)
should be enough.
Edit: fixed typo.
what a bout Dialog ?! how we can do that ?? it don't have setVisibilty()
– Adham
Jan 17 '11 at 21:46
Do you have a ProgressDialog, or a ProgressBar??
– Aman Alam
Jan 18 '11 at 7:56
2
you have a typo: should be setVisibil >i< ty
– alex
Apr 27 '12 at 12:21
add a comment |
up vote
23
down vote
ProgressBar.setVisibility(View.INVISIBLE)
should be enough.
Edit: fixed typo.
what a bout Dialog ?! how we can do that ?? it don't have setVisibilty()
– Adham
Jan 17 '11 at 21:46
Do you have a ProgressDialog, or a ProgressBar??
– Aman Alam
Jan 18 '11 at 7:56
2
you have a typo: should be setVisibil >i< ty
– alex
Apr 27 '12 at 12:21
add a comment |
up vote
23
down vote
up vote
23
down vote
ProgressBar.setVisibility(View.INVISIBLE)
should be enough.
Edit: fixed typo.
ProgressBar.setVisibility(View.INVISIBLE)
should be enough.
Edit: fixed typo.
edited Oct 2 '12 at 7:47
Leandros
14k65693
14k65693
answered Jan 17 '11 at 21:17
Jake Kalstad
1,738920
1,738920
what a bout Dialog ?! how we can do that ?? it don't have setVisibilty()
– Adham
Jan 17 '11 at 21:46
Do you have a ProgressDialog, or a ProgressBar??
– Aman Alam
Jan 18 '11 at 7:56
2
you have a typo: should be setVisibil >i< ty
– alex
Apr 27 '12 at 12:21
add a comment |
what a bout Dialog ?! how we can do that ?? it don't have setVisibilty()
– Adham
Jan 17 '11 at 21:46
Do you have a ProgressDialog, or a ProgressBar??
– Aman Alam
Jan 18 '11 at 7:56
2
you have a typo: should be setVisibil >i< ty
– alex
Apr 27 '12 at 12:21
what a bout Dialog ?! how we can do that ?? it don't have setVisibilty()
– Adham
Jan 17 '11 at 21:46
what a bout Dialog ?! how we can do that ?? it don't have setVisibilty()
– Adham
Jan 17 '11 at 21:46
Do you have a ProgressDialog, or a ProgressBar??
– Aman Alam
Jan 18 '11 at 7:56
Do you have a ProgressDialog, or a ProgressBar??
– Aman Alam
Jan 18 '11 at 7:56
2
2
you have a typo: should be setVisibil >i< ty
– alex
Apr 27 '12 at 12:21
you have a typo: should be setVisibil >i< ty
– alex
Apr 27 '12 at 12:21
add a comment |
up vote
4
down vote
"all of them are work", that sounds like it means that they work? But then why the question?
I'd say: get the view, en do
myView.setVisibility(View.GONE)
I'm sorry . they aren't .. i edited it :)
– Adham
Jan 17 '11 at 21:36
but I assume setVisibility does?
– Nanne
Jan 18 '11 at 7:43
it is not working....
– hharry
Jul 26 '13 at 6:03
add a comment |
up vote
4
down vote
"all of them are work", that sounds like it means that they work? But then why the question?
I'd say: get the view, en do
myView.setVisibility(View.GONE)
I'm sorry . they aren't .. i edited it :)
– Adham
Jan 17 '11 at 21:36
but I assume setVisibility does?
– Nanne
Jan 18 '11 at 7:43
it is not working....
– hharry
Jul 26 '13 at 6:03
add a comment |
up vote
4
down vote
up vote
4
down vote
"all of them are work", that sounds like it means that they work? But then why the question?
I'd say: get the view, en do
myView.setVisibility(View.GONE)
"all of them are work", that sounds like it means that they work? But then why the question?
I'd say: get the view, en do
myView.setVisibility(View.GONE)
answered Jan 17 '11 at 21:16
Nanne
55.3k1496142
55.3k1496142
I'm sorry . they aren't .. i edited it :)
– Adham
Jan 17 '11 at 21:36
but I assume setVisibility does?
– Nanne
Jan 18 '11 at 7:43
it is not working....
– hharry
Jul 26 '13 at 6:03
add a comment |
I'm sorry . they aren't .. i edited it :)
– Adham
Jan 17 '11 at 21:36
but I assume setVisibility does?
– Nanne
Jan 18 '11 at 7:43
it is not working....
– hharry
Jul 26 '13 at 6:03
I'm sorry . they aren't .. i edited it :)
– Adham
Jan 17 '11 at 21:36
I'm sorry . they aren't .. i edited it :)
– Adham
Jan 17 '11 at 21:36
but I assume setVisibility does?
– Nanne
Jan 18 '11 at 7:43
but I assume setVisibility does?
– Nanne
Jan 18 '11 at 7:43
it is not working....
– hharry
Jul 26 '13 at 6:03
it is not working....
– hharry
Jul 26 '13 at 6:03
add a comment |
up vote
3
down vote
ProgressBar progressBar = (ProgressBar) findViewById(R.id.progressBar);
progressBar.setVisibility(0); --visible
progressBar.setVisibility(4); --invisible
progressBar.setVisibility(8); --gone (like dismiss)
14
Why notprogressBar.setVisibility(View.Visible);
instead of using these magic numbers?
– Rafi Kamal
Jun 19 '14 at 14:44
add a comment |
up vote
3
down vote
ProgressBar progressBar = (ProgressBar) findViewById(R.id.progressBar);
progressBar.setVisibility(0); --visible
progressBar.setVisibility(4); --invisible
progressBar.setVisibility(8); --gone (like dismiss)
14
Why notprogressBar.setVisibility(View.Visible);
instead of using these magic numbers?
– Rafi Kamal
Jun 19 '14 at 14:44
add a comment |
up vote
3
down vote
up vote
3
down vote
ProgressBar progressBar = (ProgressBar) findViewById(R.id.progressBar);
progressBar.setVisibility(0); --visible
progressBar.setVisibility(4); --invisible
progressBar.setVisibility(8); --gone (like dismiss)
ProgressBar progressBar = (ProgressBar) findViewById(R.id.progressBar);
progressBar.setVisibility(0); --visible
progressBar.setVisibility(4); --invisible
progressBar.setVisibility(8); --gone (like dismiss)
answered May 7 '14 at 22:31
Stephanie
551
551
14
Why notprogressBar.setVisibility(View.Visible);
instead of using these magic numbers?
– Rafi Kamal
Jun 19 '14 at 14:44
add a comment |
14
Why notprogressBar.setVisibility(View.Visible);
instead of using these magic numbers?
– Rafi Kamal
Jun 19 '14 at 14:44
14
14
Why not
progressBar.setVisibility(View.Visible);
instead of using these magic numbers?– Rafi Kamal
Jun 19 '14 at 14:44
Why not
progressBar.setVisibility(View.Visible);
instead of using these magic numbers?– Rafi Kamal
Jun 19 '14 at 14:44
add a comment |
up vote
1
down vote
when you want to show it
progressBar.visibility = View.VISIBLE
when you want to hide it
1 progressBar.visibility = View.GONE
2 progressBar.visibility = View.INVISIBLE
add a comment |
up vote
1
down vote
when you want to show it
progressBar.visibility = View.VISIBLE
when you want to hide it
1 progressBar.visibility = View.GONE
2 progressBar.visibility = View.INVISIBLE
add a comment |
up vote
1
down vote
up vote
1
down vote
when you want to show it
progressBar.visibility = View.VISIBLE
when you want to hide it
1 progressBar.visibility = View.GONE
2 progressBar.visibility = View.INVISIBLE
when you want to show it
progressBar.visibility = View.VISIBLE
when you want to hide it
1 progressBar.visibility = View.GONE
2 progressBar.visibility = View.INVISIBLE
answered Nov 14 at 14:05
Thavath Captain
111
111
add a comment |
add a comment |
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.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- 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.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f4717975%2fhow-to-hide-progressbar-in-android%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
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