“BgTask “ ? how long execute?



“BgTask “ ? how long execute?..

Answer / babu

if you want to perform some long running in background you will do it with the help beginBackgroundTaskWithExpirationHandler:

Example:

bgTask = [app beginBackgroundTaskWithExpirationHandler:^{

[app endBackgroundTask:bgTask];

bgTask = UIBackgroundTaskInvalid;

}];

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Apple iOS Interview Questions

Can we support the same application for iphone 3gs and iphone 5, 6, 7? Why not?

0 Answers  


Explain the options and bars available in xcode 4.x workspace window in iOS operating system

0 Answers   CDC,


What is a fault?

0 Answers  


Explain retain counts in iOS operating system?

0 Answers   CDC,


What happens when you invoke a method on a nil pointer?

0 Answers  






what is the use of PO command in Xcode?

0 Answers  


How to use reusable cell in uitableview?

0 Answers  


Why do we override drawrect: method? How to explicitly call it?

0 Answers  


. List down app's state transitions when it gets launched. 

1 Answers  


What is application lifecycle in ios?

0 Answers  


what’s accessibilityhint?

0 Answers  


What is the architecture of ios?

0 Answers  


Categories