Solved the problem
I don't know how but it worked with the same code I've written in the question:
-(IBAction)launchMyApp:(id)sender
{
NSString *mystr=[[NSString alloc] initWithFormat:@"myapp://"];
NSURL *myurl=[[NSURL alloc] initWithString:mystr];
[[UIApplication sharedApplication] openURL:myurl];
}