I've looked at this code for launching a custom sheet from Apple:
I'm trying to use this code in MyDocument.m, but I don't know what to pass for the modalForWindow parameter. Everything I try gets an error. Does anyone know what to pass it to get a sheet to load in the MyDocument window?
Code:
if (!myCustomSheet)
[NSBundle loadNibNamed: @"MyCustomSheet" owner: self];
[NSApp beginSheet: myCustomSheet
modalForWindow: window
modalDelegate: self
didEndSelector: @selector(didEndSheet:returnCode:contextInfo:)
contextInfo: nil];
I'm trying to use this code in MyDocument.m, but I don't know what to pass for the modalForWindow parameter. Everything I try gets an error. Does anyone know what to pass it to get a sheet to load in the MyDocument window?