views:

7

answers:

0

I have a static library build for iPhone/iPad and I want to show a pop up right at the initialization (before the main).

My library initialize itself with:

int InitLibrary( void ) __attribute__( ( constructor ) );

And Im trying to put the following code inside InitLibrary:

UIAlertView *alert = [[UIAlertView alloc] initWithTitle:[ NSString stringWithUTF8String: "INFO" ] message:[NSString stringWithUTF8String: "Library Initialization" ] delegate:nil cancelButtonTitle:@"OK" otherButtonTitles: nil ]; [ alert show ]; [ alert release ];

But it crash, can someone point me out the "right" way to do this? tks in advance!