i can show you how to remove the punctiation easily.. i dont understand the rest.. are you trying to detect a word and then put a space???
anyways...
lets say you have a UITextView called mytextfield1 ... if it has a comma in it.. you can replace that comma with a space.... (.m file)
Code:
NSString *temptextFieldName = mytextfield1.text;
temptextFieldName = [temptextFieldName stringByReplacingOccurrencesOfString:@"," withString:@" "];
[mytextfield1 setText:temptextFieldName];
you could even replace a comma with a carriage return (going to the next line) like this...
Code:
NSString *temptextFieldName = mytextfield1.text;
temptextFieldName = [temptextFieldName stringByReplacingOccurrencesOfString:@"," withString:@" \n"];
[mytextfield1 setText:temptextFieldName];
the \n is just like hitting the return/enter key
GOOD LUCK!