iOS custom alert
-(void) customAlertForValidation: (NSString *) message
{
UIView *viewAlert = [[UIView alloc] initWithFrame:CGRectMake(0, screenHeight-145, screenWidth, 50)];
viewAlert.backgroundColor = [delegate navHeaderColor];
[self.view addSubview:viewAlert];
UILabel *lblMessage = [[UILabel alloc] initWithFrame:CGRectMake(10, 0, screenWidth-20, 50)];
lblMessage.textColor = [UIColor whiteColor];
lblMessage.numberOfLines = 2;
lblMessage.text = message;
lblMessage.font = [UIFont fontWithName:fontName size:fontTextField];
lblMessage.textAlignment = NSTextAlignmentCenter;
[viewAlert addSubview:lblMessage];
[UIView animateWithDuration:3.0
animations:^{viewAlert.alpha = 0.0;}
completion:^(BOOL finished){ [viewAlert removeFromSuperview]; }];
}