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

  • Home
  • SEARCH
  • 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 8508533
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T03:11:15+00:00 2026-06-11T03:11:15+00:00

I am working on my first native mac app after playing with iOS for

  • 0

I am working on my first native mac app after playing with iOS for a while.

I am attempting to launch a window from a menu item, but I suspect I am doing it wrong. Any IBAction I connect to buttons on this new window returns an error.

Here is what I am doing. From a menu item I launch this:

-(IBAction)displaySAInput:(id)sender{

NSLog(@"Input selected.");
inputSAViewController = [[NSWindowController alloc] initWithWindowNibName:@"InputViewController"];
[inputSAViewController showWindow:self];

This launches the InputViewController nib that is owned by the InputViewController class. I set the InputViewController class to inherit from NSWindowController.

On InputViewController.m I have tested IBActions such as:

-(IBAction)testButton:(id)sender{

NSLog(@"Data recalled?");

}

I connect this IBAction to a button through the Interface Builder. All looks okay.

When I build and open the InputViewController window I receive this error in the console before clicking anything:

Could not connect the action testButton: to target of class NSWindowController

I have searched extensively but my ignorance prevents me from connecting the dots. This thread based on a similar error with NSApplication looks promising, but I don’t quite understand what I’d need to make the connections happen related to the NSWindowController error.

This should be simple. What am I missing?

  • 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-11T03:11:17+00:00Added an answer on June 11, 2026 at 3:11 am

    Just load the NSWindow before hand and make it invisible and when the IBAction is called, just do the following:

    [myWindow setIsVisible:YES];
    [myWindow setLevel:NSFloatingWindowLevel];
    

    Yay!

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

Sidebar

Related Questions

I’m working on an app with an AIR3 iOS native extension that uses Accelerate.framework
I am attempting to get a Native C/C++ library working with Monodroid in the
I'm working on a native C++/Win32/MFC app on Windows 7. I'm using CFile to
I'm working on an app that involves displaying comments from a website. These comments
I'm in the middle of working on my first native application with networking and
I'm working with google maps. When i run my app for the first time
Working on my first serious native binding template and am making what will be
I am new to wpf and i am working on first application i have
For some weird reason, the codes below are first working, then website is redirecting
Working on my first Rails project, I used Ryan Bates' Nifty-Generators to create the

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.