fetching from NSArray
fetching from NSArray
- Subject: fetching from NSArray
- From: "Erfan Aleemullah" <email@hidden>
- Date: Tue, 2 Oct 2007 17:23:22 -0400
I'm adding NSString objects in NSArray (for storage) and then trying to
remove certain ranges from NSArray and then outputting them via NSTextview. I
keep getting errors and not sure why. I am fairly new to cocoa and
obj C. What
is the easiest way to remove objects from an array in objective C ?
Is it (getObjects:range)?
Relevant Code:
newLine = [[NSString alloc] initWithFormat:@"%0.07d: %@\n", m_lineNumber,
newLine];
m_lineNumber++; //becomes index of array
[m_storage addObject:newLine];
NSString *temp1;
NSAttributedString *attributedLine;
id* aBuffer;
Range.location = (1500*user_page); //the range is 1500 cells in array
Range.length = 1500;
[m_storage getObjects:aBuffer range:Range];
temp1 = *aBuffer; (At this point, temp1 points to the relevant location as
seen in debugger)
attributedLine = [[NSAttributedString alloc] initWithString:temp1
attributes:[NSMutableDictionary dictionary]];
[g_pMainStorage setAttributedString:attributedLine];
*Error:*
Program received signal: "EXC_BAD_ACCESS".
Unable to disassemble .objc_class_name_NSCustomPredicateOperator.
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden