NSTextAttachment *attachement = [[NSTextAttachment alloc]initWithData:nil ofType:nil];
attachement.image = [UIImage imageNamed:@"Your Image Name"];
NSAttributedString *string = [NSAttributedString attributedStringWithAttachment:attachement];
self.txtView.attributedText = string;
attachement.image = [UIImage imageNamed:@"Your Image Name"];
NSAttributedString *string = [NSAttributedString attributedStringWithAttachment:attachement];
self.txtView.attributedText = string;