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

View Single Post
Old 10-06-2008, 07:05 AM   #1 (permalink)
mladjo
Registered Member
 
Join Date: Oct 2008
Posts: 42
mladjo is on a distinguished road
Default Changing views from Navigation controller

Hi guys,

I am having some problems with changing views when I click on "Settings" button of navigation controller. To be more specific, here is my initialization code(for the button):
Code:
- (id)initWithStyle:(UITableViewStyle)style {
    // Override initWithStyle: if you create the controller programmatically and want to perform customization that is not appropriate for viewDidLoad.
    if (self = [super initWithStyle:style]) {
        self.title = @"pingdom";
        UIBarButtonItem *addButton = [[UIBarButtonItem alloc]
                                       initWithTitle:NSLocalizedString(@"Settings", @"")
                                       style:UIBarButtonItemStyleBordered
                                       target:self
                                       action:@selector(GoToSettings:)];
        self.navigationItem.rightBarButtonItem = addButton;
    }
    return self;
}
and here is the function where I tell my app delegate to change view
Code:
-(void) GoToSettings {
    LuckyAppDelegate *md = (LuckyAppDelegate *)[[UIApplication sharedApplication] delegate];
    [md CheckViewToSettingsView:self];
}
When I use this code outside the button function it works flawlessly. However, inside it, it just pops up debugger mode.

I hope that you understand my problem and have the appropriate solution

Regardz,
Mladen
mladjo is offline   Reply With Quote
 

» Advertisements
» Online Users: 366
11 members and 355 guests
Art, bebshol53, blackcat_tq, eski, hacker073, Kirkout, Kryckter, nmi300, Objective Zero, Oral B, TunaNugget
Most users ever online was 1,387, 04-10-2012 at 04:21 AM.
» Stats
Members: 175,561
Threads: 94,079
Posts: 402,746
Top Poster: BrianSlick (7,990)
Welcome to our newest member, benney_swet
Powered by vBadvanced CMPS v3.1.0

All times are GMT -5. The time now is 10:10 PM.
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.