FROM : Gregor Brandt
DATE : Fri Nov 09 23:45:32 2007
The following code snippet compiles fine but gives an bad access error
on run....any ideas
NSString *projectName;
NSString *title = @"This is a test";
// and parse the project name to remove the [TM] from the end
NSUInteger realLength = title.length - 4;
if ( realLength > 0 )
{
[projectName initWithString:[title
substringToIndex:realLength]];
}
Thanks
Gregor
DATE : Fri Nov 09 23:45:32 2007
The following code snippet compiles fine but gives an bad access error
on run....any ideas
NSString *projectName;
NSString *title = @"This is a test";
// and parse the project name to remove the [TM] from the end
NSUInteger realLength = title.length - 4;
if ( realLength > 0 )
{
[projectName initWithString:[title
substringToIndex:realLength]];
}
Thanks
Gregor
| Related mails | Author | Date |
|---|---|---|
| Gregor Brandt | Nov 9, 23:45 | |
| John Stiles | Nov 9, 23:51 | |
| I. Savant | Nov 9, 23:52 | |
| Gregor Brandt | Nov 9, 23:56 |






Cocoa mail archive

