If you are calling your updateUI
method from a tread other than the main thread, the UI is not guaranteed to update immediately. It can happen in 20 seconds, 45 seconds or never, depending when the next UI element requests the UI to update.
Try dispatching to the main thread before calling any UIKit code:
-(void)updateUI
{
dispatch_async(dispatch_get_main_queue(), ^{
_syncCountLbl.text=[Global retrieveFromUserDefaults:@"dbCountKey"]
if ([_syncCountLbl.text isEqualToString:@"0"]) {
[_syncCountLbl setHidden:YES];
}
else
[_syncCountLbl setHidden:NO];
});
}