iOS tabBarItem badge value change from any View
<p>Im developing an iOS app using objective c. in my app if user is not register then register view controller is <code>rootViewController</code>. if user is register then <code>tabBarController</code> having three tabs is <code>rootViewController</code>. i have to set <code>tabBarItem</code> badge value from any view controller. suppose if i am on third tab and it is having segue with another view controller and i am on that view controller, i have to change the <code>tabBarItem</code> badge value of first view controller from here.   in my case the <code>tabBarItem</code> badge value update only i go to that tab as i am using </p>

<pre><code>NSString *upcomingcount=[NSString stringWithFormat:@"%lu",(unsigned long)self.arrbadge.count];
            self.navigationController.tabBarItem.badgeValue=upcomingcount;
</code></pre>

<p>in viewwillappear.</p>

<p>is there any way to set the badgeValue from any <code>ViewController</code>? i want to update badge value from any <code>ViewController</code> </p>