Question: I need to block the interface until the `MBProgressHUD` operation is done. I did refer this thread,

[Block interface until operation is done](https://stackoverflow.com/questions/8628981/block-interface-untill-operation-is-done)

According to it, we should disable each individual item which wont work for me. My case is I need to disable user from clicking back button. I did try `HUD.userInteractionEnabled = YES` which disable every controller except the back button. Is there any way of blocking user from popping out from that controller?

Regards,  

Dilshan

Answer: 
if u dont find a proper way to do that, you can ignore the whole user interaction by

```
[[UIApplication sharedApplication] beginIgnoringInteractionEvents];

```

.U can stop this by

```
[[UIApplication sharedApplication] endIgnoringInteractionEvents];

```
This is how I add the `MBProgressHUD` to my view and it blocks all input until it is removed:

```
MBProgressHUD HUD = [[MBProgressHUD alloc] initWithView:self.view];
HUD.opacity = 0.7f;

[self.view addSubview:HUD];

HUD.delegate = self;
[HUD show:YES];

```

**Note:** `self` is the view controller the HUD is being add to