• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag
 

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Why won't my file load?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Why won't my file load?


  • Subject: Re: Why won't my file load?
  • From: Chris Gehlker <email@hidden>
  • Date: Tue, 12 Feb 2002 19:02:48 -0700

On 2/12/02 3:06 PM, "Chris Gehlker" <email@hidden> wrote

> I'm working on a little IDE for Ruby but I can't get saved files to reload.
> Here is my code:
>
> - (BOOL)loadDataRepresentation:(NSData *)data ofType:(NSString *)aType
> {
> NSString *test;
> NSString *aString = [[NSString alloc] initWithData:data
>
> encoding:NSASCIIStringEncoding];
> NSLog(@"%@", aString); // a nice string with whatever was saved
> [sourceView setString:aString];
> test = [sourceView string];
> NSLog(@"%@", test); // always says: (null)
> [aString release];
> if (test == nil)
> return NO;
> return YES;
> }
>
> Sending setString to NSTextViews is working elsewhere in the program so I'm
> stumped. Any help apprecieated.

Never mind. I didn't realize that this runs before the nib loads.
--
Some people say Windows users have an inferiority complex.
That's not true. It's not a complex.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

  • Follow-Ups:
    • Re: Why won't my file load?
      • From: Ben Hines <email@hidden>
References: 
 >Why won't my file load? (From: Chris Gehlker <email@hidden>)

  • Prev by Date: Re: Strings
  • Next by Date: Sprite lib
  • Previous by thread: Why won't my file load?
  • Next by thread: Re: Why won't my file load?
  • Index(es):
    • Date
    • Thread