Advertise Mobile SDKs Books Events Forum News Social Networking Support Us
Follow @iphonedevsdk on Twitter

Interface 2, Advanced iOS
Mockup & Code Gen
($9.99)

Make your own iPhone apps
and run them live!
(free)

Pic Frame Dynamo: Photo Editing
($0.99)

Abiliator
($1.99)

Want your application or service advertised on iPhone Dev SDK?

Go Back   iPhone Dev SDK Forum > iPhone SDK Development Forums > iPhone SDK Development

Reply
 
LinkBack Thread Tools Display Modes
Old 09-19-2010, 10:55 PM   #1 (permalink)
Registered Member
 
Join Date: Apr 2010
Posts: 5
idesiteacher is on a distinguished road
Default App with Login page and then NavBar + Table View + Tab Bar

Gurus,

I'm trying to develop an sample app, having the following features.

- Application starts with an Logon on page: User ID, Password and Logon button
- On clicking the logon button, after validating the credentials, we've to take the user to the next screen with
- an Navigation Bar on the top (essentially an UINavigationController)
- Table view
- Tab Bar in the bottom

Without the logon page, I'm able to create the app, by following the steps given by DevTeamOfOne at this post. However, not sure how can I achieve it having an logon screen at first.

Could anyone help please?

Thanks
idesiteacher is offline   Reply With Quote
Old 09-20-2010, 12:49 AM   #2 (permalink)
Registered Member
 
Join Date: Sep 2010
Posts: 3
capsen is on a distinguished road
Default

Quote:
Originally Posted by idesiteacher View Post
Gurus,

I'm trying to develop an sample app, having the following features.

- Application starts with an Logon on page: User ID, Password and Logon button
- On clicking the logon button, after validating the credentials, we've to take the user to the next screen with
- an Navigation Bar on the top (essentially an UINavigationController)
- Table view
- Tab Bar in the bottom

Without the logon page, I'm able to create the app, by following the steps given by DevTeamOfOne at this post. However, not sure how can I achieve it having an logon screen at first.

Could anyone help please?

Thanks
You have two way to achieve this.
First, Set the login screen as the mainviewcontroller. after login add navigation view to the main view.
Second, Set the login screen as the root view for the navigation view. hide the navigation bar on the root view.
capsen is offline   Reply With Quote
Old 09-23-2010, 09:39 AM   #3 (permalink)
Registered Member
 
Join Date: Apr 2010
Posts: 5
idesiteacher is on a distinguished road
Default

Thanks capsen. I would try one of this method.
idesiteacher is offline   Reply With Quote
Old 02-14-2011, 11:58 PM   #4 (permalink)
Registered Member
 
Join Date: Oct 2010
Posts: 103
TheRekz is on a distinguished road
Default

Quote:
Originally Posted by idesiteacher View Post
Thanks capsen. I would try one of this method.
Can someone show a code sample for no. 1?
TheRekz is offline   Reply With Quote
Old 02-15-2011, 05:36 AM   #5 (permalink)
- U haz disappoint -
 
Join Date: Jan 2010
Location: Belgium
Posts: 489
jNoxx is on a distinguished road
Send a message via MSN to jNoxx Send a message via Skype™ to jNoxx
Default

Add a modalviewcontroller on startup on top, and if the credentials are correct after pressing login, dismiss it, so user can use the app. Not that hard I guess..
jNoxx is offline   Reply With Quote
Old 02-15-2011, 02:52 PM   #6 (permalink)
Awesome
 
Esko2300's Avatar
 
Join Date: Jun 2009
Location: New York, N.Y.
Posts: 389
Esko2300 is on a distinguished road
Default

this is how i achieve #1 in my application, i dont load up the tabBarcontroller initally when the application loads. first i load my log in controller, then when the server sends back a messege stating if the user has logged in or not then i show my tabBarcontroller

in your applicaitons delegate you have these lines of code in the - (BOOL)applicationUIApplication *)application didFinishLaunchingWithOptionsNSDictionary *)launchOptions method
Code:
[self.window addSubview:tabBarController.view];
[self.window makeKeyAndVisible];
;

now just place an object of your log in view controller before these lines of code and add it to the window like so
Code:
MyLogInController *logInVC = [[MyLogInController alloc]initWithNibName:@"MyLogInController" bundle:nil];
[self.window addSubview:logInVC.view];
[self.window makeKeyAndVisible];
return YES;
;


In this example I have a tabController so just place the tab controller on the window after you have completed validating users log in info like so

1)make a reference to the application delegate
2)add tabBarController to view

Code:
MyApplicationDelegate *del = (MyApplicationDelegate)[[UIApplication sharedApplication]delegate];
[del.window addSubview:tabBarController.view];
just make sure you release the log in view controller before you do it or it will just be sitting in the background using memory

Last edited by Esko2300; 02-15-2011 at 04:51 PM.
Esko2300 is offline   Reply With Quote
Reply

Bookmarks

Tags
logon, navigation bar, tab bar

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



» Advertisements
» Online Users: 311
14 members and 297 guests
2ndSegment, cayladv57, cgokey, dermotos, djohnson, Domele, Hamad, linkmx, markuschow, pungs, Sloshmonster, teebee74, v1n2e7t
Most users ever online was 1,387, 04-10-2012 at 04:21 AM.
» Stats
Members: 175,655
Threads: 94,116
Posts: 402,889
Top Poster: BrianSlick (7,990)
Welcome to our newest member, pungs
Powered by vBadvanced CMPS v3.1.0

All times are GMT -5. The time now is 11:00 PM.
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0