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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T20:03:53+00:00 2026-06-12T20:03:53+00:00

I am a iOS developer and going to develop an OS X application. However

  • 0

I am a iOS developer and going to develop an OS X application.
However they are so different from each other.

I want to add a splash screen at the application startup.

- (void) applicationDidFinishLaunching:(NSNotification *)aNotification {

 // Hide main window
 [self.window orderOut:nil];

 SplashWindowController *splashWindowController = [[SplashWindowController alloc] initWithWindowNibName:@"SplashWindowController"];

 [NSApp runModalForWindow:splashWindowController.window];
 [splashWindowController release];

 // Show main window
 ...

And here is “SplashWindowController.m”

- (void)windowDidLoad {
  [super windowDidLoad];

  [NSTimer scheduledTimerWithTimeInterval:2.0 target:self selector:@selector(hideSplash) userInfo:nil repeats:NO];
}

- (void)hideSplash {
  [NSApp endSheet:self.window];
  [self.window orderOut:nil];
}

I can see the appeared splash, but hideSplash function is never called.
What’s the reason?

  • 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-12T20:03:53+00:00Added an answer on June 12, 2026 at 8:03 pm

    I’m wondering that you don’t get an error, but this line has a typo:

    [NSTimer scheduledTimerWithTimeInterval:2.0 target self selector:@selector(hideSplash) userInfo:nil repeats:NO];
    

    it should be

    [NSTimer scheduledTimerWithTimeInterval:2.0 target:self selector:@selector(hideSplash) userInfo:nil repeats:NO];
    

    On the other hand, you could try this one:

    NSTimer *theTimer = [NSTimer scheduledTimerWithTimeInterval:2.0 target:self selector:@selector(hideSplash) userInfo:nil repeats:NO];
    [[NSRunLoop mainRunLoop] addTimer:theTimer forMode:NSRunLoopCommonModes];
    

    I’m not sure if the [NSTimer…] is destroyed too soon… Assigning it to an instance should be fine. Also afaik the run loop is interrupted so you could try adding the timer to the main run loop.

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

Sidebar

Related Questions

I am going to develop an iOS application for a customer of mine and
I'm new ios developer, I want to compare and change attributes Array1 = (object1,object2,
We are coming up to our iOS Developer Program renewal date and I want
I'm a iOS Application developer.I need some similar tasks in many projects as example
I'm an experienced C/C++ Windows developer writing my first real iOS application. Since I
I'm going to develop apps for iOS, Android and Windows Phone that will be
We are going to develop a mobile app (iOS and Android), which should provide
I am a fairly new IOS developer - on the whole everything is going
If I subscribe to the iOS Developer Enterprise Program, and want to restrict use
I am going to develop an application which will be cross platform and it

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.