You may try something like this:
@property (nonatomic, strong) UIView *shadowView;
- (void)willPresentActionSheet:(UIActionSheet *)actionSheet
{
if (!self.shadowView)
{
self.shadowView = [[UIView alloc]initWithFrame:self.view.bounds];
self.shadowView.backgroundColor = [UIColor colorWithRed:(42.0/255.0) green:(42.0/255.0) blue:(42.0/255.0) alpha:1.0];
self.shadowView.alpha = 0.7;
[self.view addSubview:self.shadowView];
}
else
{
self.shadowView.alpha = 0.7;
}
}
- (void)actionSheet:(UIActionSheet *)actionSheet clickedButtonAtIndex:(NSInteger)buttonIndex
{
self.shadowView.alpha = 0.0;
}