RoyaltyInCode
RoyaltyInCode

Reputation: 11

ARC Semantic Issue Objective-c

I am creating an ios application in objective-c with xcode and came across a strange error. the code is:

#import "LAAppDelegate.h"
#import "Reachability.h"

@implementation LAAppDelegate

- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:    (NSDictionary *)launchOptions
{
    NetworkStatus networkStatus =
        [[Reachability reachabilityForInternetConnection]
         currentReachabilityStatus];
    if (networkStatus == NotReachable) {
        UIAlertView *alert = [[UIAlertView alloc]
        initWithTite:@"Network Unavailable"
        message:@"Lazuli requires an internet connection"
        delegate:nil
        cancelButtonTitle:@"Ignore"
        otherButtonTitles:nil];
    [alert show];

    }

   // Override point for customization after application launch.
   return YES;
}

I keep getting the error: "No visible @interface for 'UIAlertView' declares the selector 'initWithTite:message:delegate:cancelButtonTitle:otherButtonTitles:' "

I am a beginner and need help!

Upvotes: 0

Views: 2877

Answers (1)

DrummerB
DrummerB

Reputation: 40211

You have a typo in your method call. It's initWithTitle..., not initWithTite...

Upvotes: 5

Related Questions