• 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: Number formatting
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Number formatting


  • Subject: Re: Number formatting
  • From: j o a r <email@hidden>
  • Date: Sat, 11 Oct 2003 02:42:41 +0200

On 2003-10-11, at 00.25, John MacMullin wrote:

I did try a couple of other variations and the program "kabooms".

Where is it crashing? How is it crashing? Use the run log and debugger to find out!

fileFieldFourNumber = [fileFieldFourNumber stringByAppendingString:[numberFormatter stringForObjectValue: [[[self testFile] objectAtIndex: i] objectAtIndex: fieldFourNumberDef]]];

Replace the line of code above with something like this (temporary, to track problems):

NSArray *arr1 = [self testFile];
NSLog(@"arr1 count: %d, i: %d", [arr1 count], i);
NSArray *arr2 = [arr1 objectAtIndex: i];
NSLog(@"arr2 count: %d, fieldFourNumberDef: %d", [arr2 count], fieldFourNumberDef);
id obj = [arr2 objectAtIndex: fieldFourNumberDef];
NSLog(@"obj: %@, fileFieldFourNumber: %@", obj, fileFieldFourNumber);
NSString *formattedString = [numberFormatter stringForObjectValue: obj];
NSLog(@"formattedString: %@", formattedString);
fileFieldFourNumber = [fileFieldFourNumber stringByAppendingString: formattedString];
NSLog(@"fileFieldFourNumber: %@", fileFieldFourNumber);

Do you see anything suspicious from the logs that are printed?

Given the degree of help that I have had with the text architecture I would be happy to donate the code.

Donate crashing code? :)

j o a r
_______________________________________________
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: Number formatting
      • From: John MacMullin <email@hidden>
References: 
 >Re: Number formatting (From: John MacMullin <email@hidden>)

  • Prev by Date: Re: Loading a TTF font
  • Next by Date: Re: Sending data to libxslt
  • Previous by thread: Re: Number formatting
  • Next by thread: Re: Number formatting
  • Index(es):
    • Date
    • Thread