What OS are you trying to do this with? I got this to work with both OS 3.0 Simulator and OS 3.0:
UIAlertView * alert = [ [ UIAlertView alloc ] initWithTitle:@"Alert" message:@"Alert" delegate:self cancelButtonTitle:@"OK" otherButtonTitles:nil ]; alert.transform = CGAffineTransformTranslate( alert.transform, 0.0, 100.0 ); [ alert show ];
CGAffineTransformTranslate takes three arguments: the existing transform, the x transform, and the y transform. In the example I used, the warning view appeared 100 pixels higher than usual. Try it and see what happens.
In addition, I am pretty sure that you can change the frame before showing a warning, as it seems to set the notification frame to init by default for the center of the entire screen.
LucasTizma
source share