When you are loading your picture, just add a boolean behind the statement that goes like isLoaded = true; and then use that as variable or use the variable with you picture, lets say it is img and do something like if (img != null) {}
And please don’t move the topics back to the wrong cathegory, after someone (only people with Trust level 3 can move others topics) moved your question to the right cathegory.