Accessing & Messaging DetailVC in a UISplitViewController
===

I'm using a UISplitViewController that uses two UINavigationController's, one for MasterVC and another for the DetailVC. I'm trying to send messages to the DetailVC's topViewController from a VC in the MasterVC's navigation stack. This is how I'm accessing the receiving VC.

    UIWindow *window = [[UIApplication sharedApplication] keyWindow];

    UISplitViewController *splitViewController = (UISplitViewController*)window.rootViewController;

    UINavigationController *navigationController = (UINavigationController*)[splitViewController.viewControllers objectAtIndex:1];

    DefaultDetailedViewController_iPad *defaultVC = (DefaultDetailedViewController_iPad*)navigationController.topViewController;
    
    if ( [defaultVC conformsToProtocol:@protocol(MapDelegate)] ) {
        [defaultVC clearPreviousAnnotations];
    }

The IF executes but the clearPreviousAnnotations does not get called. What's the best way to access and message the DetailVC?


I should also say that I'm a hobbyist and very much new to programming.


Thank you.
