I am currently trying to compare two string to see if they're equal to each other. The two values should be equal but when debugging it's giving me a false return. What gives? NSString *itemA = [DictionaryA valueForKey:@"FirstProcessIdentifier"]; NSWorkspace *workSpace = [NSWorkspace sharedWorkspace]; for (NSDictionary *apps in [workSpace launchedApplications]) { if ( [itemA isEqualTo: [apps valueForKey: @"NSApplicationProcessIdentifier"]] ) { NSLog(@"this should run" ); } }
the NSString "itemA" should contain for example "312" pid one of the "[apps valueForKey: @"NSApplicationProcessIdentifier"]" should also return the same "312" When I NSLog both, there is a matching set "312", but the if statement is returning false...any tips? Thanks, John _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com