Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8259527
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T02:53:09+00:00 2026-06-08T02:53:09+00:00

I am new to XCODE, but I am trying to learn. Basically my project

  • 0

I am new to XCODE, but I am trying to learn. Basically my project is a rework of Nada Jaksic’s Creating a table-based form on the iPhone”. I would appreciate being informed where I went wrong in my coding, so that I can learn from my mistakes. Any and all help is definitely appreciated!

From the SignupTableViewController.h file:

#import <UIKit/UIKit.h>

@interface SignupTableViewController : UITableViewController<UITextFieldDelegate,   UIActionSheetDelegate>

{


    IBOutlet UITableViewCell *cellExaminername;
    IBOutlet UITableViewCell *cellExamineraddress;
    IBOutlet UITableViewCell *cellExaminercity;
    IBOutlet UITableViewCell *cellExaminerstate;
    IBOutlet UITableViewCell *cellExaminerzip;
    IBOutlet UITableViewCell *cellExamineremail;
    IBOutlet UITableViewCell *cellSearchthroughdate;
    IBOutlet UITableViewCell *cellTitleheldby;
    IBOutlet UITableViewCell *cellPropertyaddress1;
    IBOutlet UITableViewCell *cellPropertyaddress2;
    IBOutlet UITableViewCell *cellPropertycity;
    IBOutlet UITableViewCell *cellPropertystate;
    IBOutlet UITableViewCell *cellProperyzip;
    IBOutlet UITableViewCell *cellTitlesearchnotes;    



    IBOutlet UITextField* txtExaminername;
    IBOutlet UITextField* txtExamineraddress;
    IBOutlet UITextField* txtExaminercity;
    IBOutlet UITextField* txtExaminerstate;
    IBOutlet UITextField* txtExaminerzip;
    IBOutlet UITextField* txtExamineremail;
    IBOutlet UITextField* txtSearchthroughdate;
    IBOutlet UITextField* txtTitleheldby;
    IBOutlet UITextField* txtPropertyaddress1;
    IBOutlet UITextField* txtPropertyaddress2;
    IBOutlet UITextField* txtPropertycity;
    IBOutlet UITextField* txtPropertystate;
    IBOutlet UITextField* txtPropertyzip;
    IBOutlet UITextField* txtTitlesearchnotes;

    UIActivityIndicatorView* activityIndicator;


}

@property (nonatomic, retain) IBOutlet UITableViewCell *cellExaminername;
@property (nonatomic, retain) IBOutlet UITableViewCell *cellExamineraddress;
@property (nonatomic, retain) IBOutlet UITableViewCell *cellExaminercity;
@property (nonatomic, retain) IBOutlet UITableViewCell *cellExaminerstate;
@property (nonatomic, retain) IBOutlet UITableViewCell *cellExaminerzip;
@property (nonatomic, retain) IBOutlet UITableViewCell *cellExamineremail;
@property (nonatomic, retain) IBOutlet UITableViewCell *cellSearchthroughdate;
@property (nonatomic, retain) IBOutlet UITableViewCell *cellTitleheldby;
@property (nonatomic, retain) IBOutlet UITableViewCell *cellPropertyaddress1;
@property (nonatomic, retain) IBOutlet UITableViewCell *cellPropertyaddress2;
@property (nonatomic, retain) IBOutlet UITableViewCell *cellPropertycity;
@property (nonatomic, retain) IBOutlet UITableViewCell *cellPropertystate;
@property (nonatomic, retain) IBOutlet UITableViewCell *cellProperyzip;
@property (nonatomic, retain) IBOutlet UITableViewCell *cellTitlesearchnotes;


@property (nonatomic, retain) IBOutlet UITextField* txtExaminername;
@property (nonatomic, retain) IBOutlet UITextField* txtExamineraddress;
@property (nonatomic, retain) IBOutlet UITextField* txtExaminercity;
@property (nonatomic, retain) IBOutlet UITextField* txtExaminerstate;
@property (nonatomic, retain) IBOutlet UITextField* txtExaminerzip;
@property (nonatomic, retain) IBOutlet UITextField* txtExamineremail;
@property (nonatomic, retain) IBOutlet UITextField* txtSearchthroughdate;
@property (nonatomic, retain) IBOutlet UITextField* txtTitleheldby;
@property (nonatomic, retain) IBOutlet UITextField* txtPropertyaddress1;
@property (nonatomic, retain) IBOutlet UITextField* txtPropertyaddress2;
@property (nonatomic, retain) IBOutlet UITextField* txtPropertycity;
@property (nonatomic, retain) IBOutlet UITextField* txtPropertystate;
@property (nonatomic, retain) IBOutlet UITextField* txtPropertyzip;
@property (nonatomic, retain) IBOutlet UITextField* txtTitlesearchnotes;
-(void)signup;

@end

From my SignupTableViewController.m file:

#import "SignupTableViewController.h"

@implementation SignupTableViewController
@synthesize  cellExaminername, cellExamineraddress, cellExaminercity, cellExaminerstate,    cellExaminerzip, cellExamineremail, cellSearchthroughdate, cellTitleheldby, cellPropertyaddress1, cellPropertyaddress2, cellPropertycity, cellPropertystate, cellProperyzip, cellTitlesearchnotes;
@synthesize  txtExaminername, txtExamineraddress, txtExaminercity, txtExaminerstate, txtExaminerzip, txtExamineremail, txtSearchthroughdate, txtTitleheldby, txtPropertyaddress1, txtPropertyaddress2, txtPropertycity, txtPropertystate, txtPropertyzip, txtTitlesearchnotes;

#pragma mark -
#pragma mark View lifecycle


- (void)viewDidLoad 
{
    [super viewDidLoad];

    // Uncomment the following line to preserve selection between presentations.
    //self.clearsSelectionOnViewWillAppear = NO;

    UIBarButtonItem* btnSubmitSignup = [[UIBarButtonItem alloc]initWithTitle:NSLocalizedString(@"Join",@"") style:UIBarButtonItemStylePlain target:self action:@selector(signup)];
    [[self navigationItem] setRightBarButtonItem:btnSubmitSignup];
}


#pragma mark -
#pragma mark Table view data source

- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView {
// Return the number of sections.
    return 1;
}


- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section   {
    // Return the number of rows in the section.
    return 14;
}


// Customize the appearance of table view cells.
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath 
{       

    if (indexPath.row == 0) {
        return cellExaminername;
    }
    if (indexPath.row == 1) {
        return cellExamineraddress;
    }
    if (indexPath.row == 2) {
        return cellExaminercity;
    }
    if (indexPath.row == 3) {
        return cellExaminerstate;
    }
    if (indexPath.row == 4) {
        return cellExaminerzip;
    }    
    if (indexPath.row == 5) {
        return cellExamineremail;
    }    
    if (indexPath.row == 6) {
        return cellSearchthroughdate;
    }
    if (indexPath.row == 7) {
        return cellTitleheldby;
    }
    if (indexPath.row == 8) {
        return cellPropertyaddress1;
    }      
    if (indexPath.row == 9) {
        return cellPropertyaddress2;
    }     
    if (indexPath.row == 10) {
        return cellPropertycity;
    }  
    if (indexPath.row == 11) {
        return cellPropertystate;
    }    
    if (indexPath.row == 12) {
        return cellProperyzip;
    }     
    if (indexPath.row == 13) {
        return cellTitlesearchnotes;
    }

}

#pragma mark -
#pragma mark Table view delegate

- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath {
    // Navigation logic may go here. Create and push another view controller.
    /*
     <#DetailViewController#> *detailViewController = [[<#DetailViewController#> alloc] initWithNibName:@"<#Nib name#>" bundle:nil];
     // ...
     // Pass the selected object to the new view controller.
     [self.navigationController pushViewController:detailViewController animated:YES];
     [detailViewController release];
     */
}

- (BOOL)textFieldShouldReturn:(UITextField *)textField
{ 
    [textField resignFirstResponder];
    return YES;
}

- (void)textFieldDidBeginEditing:(UITextField *)textField




#pragma mark -
#pragma mark Memory management
-(void)didReceiveMemoryWarning {
    // Releases the view if it doesn't have a superview.
    [super didReceiveMemoryWarning];

    // Relinquish ownership any cached data, images, etc that aren't in use.
}

- (void)viewDidUnload {
    // Relinquish ownership of anything that can be recreated in viewDidLoad or on demand.
    // For example: self.myOutlet = nil;
}

-(void) signup
{
    // make sure the keyboard is hidden
    [txtExaminername resignFirstResponder];
    [txtExamineraddress resignFirstResponder];
    [txtExaminercity resignFirstResponder];
    [txtExaminerstate resignFirstResponder];
    [txtExaminerzip resignFirstResponder];
        [txtExamineremail resignFirstResponder];
    [txtSearchthroughdate resignFirstResponder];
    [txtTitleheldby resignFirstResponder];
    [txtPropertyaddress1 resignFirstResponder];
    [txtPropertyaddress2 resignFirstResponder];
    [txtPropertycity resignFirstResponder];    
    [txtPropertystate resignFirstResponder];
    [txtPropertyzip resignFirstResponder];
    [txtTitlesearchnotes resignFirstResponder];



    activityIndicator = [[UIActivityIndicatorView alloc]    initWithActivityIndicatorStyle:UIActivityIndicatorViewStyleWhite];
    [activityIndicator setCenter:CGPointMake(self.view.frame.size.width/2.0, self.view.frame.size.height/2.0+20)]; 
    [activityIndicator startAnimating];
    [self.view addSubview:activityIndicator];   

    if (![self validateSignupForm])
        return;

    //do your signup code here

}

-(BOOL)validateSignupForm
{
    BOOL rtn = YES; 
    // Declare your Alert,  NSArray, increment int
    UIAlertView *alert = [[UIAlertView alloc] initWithTitle:nil     message:NSLocalizedString(@"FormIncomplete", @"") delegate:self cancelButtonTitle:@"OK" otherButtonTitles:nil];
    NSArray *fieldArray;    
    int i = 0;

    // Load up our field array with the UITextField Values
    fieldArray = [NSArray arrayWithObjects: 
                  [NSString stringWithFormat:@"%@",txtExaminername.text], 
                  [NSString stringWithFormat:@"%@",txtExamineraddress.text], 
                  [NSString stringWithFormat:@"%@",txtExaminercity.text], 
                  [NSString stringWithFormat:@"%@",txtExaminerstate.text], 
                  [NSString stringWithFormat:@"%@",txtExaminerzip.text],
                  [NSString stringWithFormat:@"%@",txtExamineremail],
                  [NSString stringWithFormat:@"%@",txtSearchthroughdate.text], 
                  [NSString stringWithFormat:@"%@",txtTitleheldby.text], 
                  [NSString stringWithFormat:@"%@",txtPropertyaddress1.text], 
                  [NSString stringWithFormat:@"%@",txtPropertyaddress2.text], 
                  [NSString stringWithFormat:@"%@",txtPropertycity.text],                  
                  [NSString stringWithFormat:@"%@",txtPropertystate.text], 
                  [NSString stringWithFormat:@"%@",txtPropertyzip.text],                  
                  [NSString stringWithFormat:@"%@",txtTitlesearchnotes.text]];



    // loop through the array, alert if text field is empty, and break the the loop, other wise increment i  
    for (NSString *fieldText in fieldArray){
        NSLog(fieldText); // make sure all is reading correctly in the console
        if([fieldText isEqualToString:@""]){            
            [alert show];   
            rtn = NO;
            break; // break out!!
        }
        i++;        
     }

    // check that all the field were passed (i == array.count) 
    //if(i == [[NSNumber numberWithInt: fieldArray.count] intValue]){
    //NSLog(@"Passed validation..."); 
    //rtn = YES;           
    // {

    //if (rtn)


    @end
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-08T02:53:10+00:00Added an answer on June 8, 2026 at 2:53 am

    Your -validateSignupForm method is missing a closing }.

    A hint that this might be true is Xcode’s desire to indent @end.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want to create a new project in Xcode (4.2), but I don't need
I am pretty new to xcode so forgive my mistakes but I am trying
I'm trying to build a new Xcode project targeting the 10.7 Mac SDK (and
I'm still relatively new to XCode. I'm trying to build an iPhone application and
I am trying to compile my project in Xcode. But i am getting the
I am new to Cocoa and Xcode, but I really do want to learn.
Hi I'm new to Xcode. I'm trying to learn c++ and I was wondering
Im new to shaders and I'm trying to learn the basics. But everytime I
I'm new to Xcode. This is probably a very simple question to you, but
Lets go from the start Created New Xcode project,opened interface builder dragged one NSButton

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.