advertisement

Article:
  Adding Spit and Polish to Your Cocoa App
Subject:   Didn't Compile
Date:   2002-06-14 16:47:13
From:   johnts
After the first changes, when the article said to compile and try it, I got syntax errors, even after copying the code from the page. I had to change it to:


- (BOOL)application:(NSApplication *)theApplication
openFile:(NSString *)filename
{
NSDocumentController *dc;
id doc;
dc = [NSDocumentController sharedDocumentController];
doc = [dc openDocumentWithContentsOfFile:filename display:YES];
return ( doc != nil);



}


(it complained about the declaration of doc as it was.)


1 to 1 of 1
  1. Michael Beam photo Didn't Compile
    2002-06-17 19:19:32  Michael Beam | O'Reilly Author [View]

    • order of statements in method
      2002-06-19 22:13:44  psheldon [View]

1 to 1 of 1