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 8498267
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T00:21:21+00:00 2026-06-11T00:21:21+00:00

That’s the first time i post on this site. I explain, i have to

  • 0

That’s the first time i post on this site.

I explain, i have to work on an already advanced project in ios.
I’m new in objective-c and it’s a quite strange language when you come from java.

I have a strange issue.

In the app there is a login screen, you put mail and pass, click on a button and you go on the main view. It’s work perfectly.

What i want to do is autologin. I use keychains for that, store it, retrieve it, populate my user and pass with. It’s works perfectly.
If my user click on the login button it’s also work perfectly.

But if i call the function myself with the code, it doesn’t change the view. I can’t understand why.

I put here the code where i think the change is called.

if ([result isEqualToString:@"1"]) {


        NSUserDefaults *userDefaults = [NSUserDefaults standardUserDefaults];
        [userDefaults setObject:Email.text forKey:@"email"];

        UIAlertView *alert = [[UIAlertView alloc]initWithTitle:@"Welcom back to FriendsCam!" message:@"Start sharing your video" delegate:self cancelButtonTitle:@"OK" otherButtonTitles:nil];

        [alert show];
        //Email.text     = nil;
        //Password.text  = nil;

        UIStoryboard *MainStoryboard_iPhone=[UIStoryboard storyboardWithName:@"MainStoryboard_iPhone" bundle:nil]; 
        self.view.window.rootViewController=[MainStoryboard_iPhone instantiateInitialViewController];

So this code is in a function who is called by the functions called when the button login is pressed if all field are correctly fill.
It work when a user manually click on the button but not when i call the button’s function myself in code but the alert “welcome back” of good login show in both cases. it’s only the jump in the storyboard who is broken.

Can someone explain why ? It will be very kind.

  • 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-11T00:21:23+00:00Added an answer on June 11, 2026 at 12:21 am

    Ok i find the solution.

    I was firing my method to quickly, something related with loading time of the view i think.

    I delay my call with a nstimer and all work perfectly.

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

Sidebar

Related Questions

I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function
That should be simple web site but with an editable tree. This tree will
I have a French site that I want to parse, but am running into
I'm parsing an RSS feed that has an ’ in it. SimpleXML turns this
That's my first post here. Thanks in advance everyone that collaborates with me. I'm
That title is presumably awfully worded. I have some PostgreSQL tables. There is a
That's pretty much what I am trying to accomplish. To have each image appear
That's how cell selection looks in MS Excel: Is it possible to have the
That sounds complicated, doesn't it... actually it's quite easy: I have a multi-language app
That's how I'm new in here on the website so it would be super

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.