My problem is that I am declaring some strings, arrays.... in an implementation file, and I wanna a kind of include (like in PHP) to avoid declaration errors...
For example in the code bellow coordi (see the end of the last line) an NSString which is declared in another implementation file, in my code now, xCode is giving me an error saying that coordi is not declared, however it is declared in another implementation file.
- (IBAction)searchButton:(id)sender { if (_searchQuery.text.length < 3 ) { UIAlertView *alert = [[UIAlertView alloc] initWithTitle:@"No destination !" message:@"Please enter a destination !" delegate:nil cancelButtonTitle:@"Dismiss" otherButtonTitles:nil]; [alert show]; } else { [self performSegueWithIdentifier:@"seg_map" sender:self]; NSString *query = [[self.searchQuery text] stringByReplacingOccurrencesOfString: @" " withString:@"\%20"]; NSURL *jsonURL = [NSURL URLWithString:[NSString stringWithFormat:@"https://maps.googleapis.com/maps/api/directions/json?origin=%@&destination=%@&sensor=false", coordi, query]]; }}
Any ideas on how to solve this issue ?