Uitextview NsmutableArray を反復処理したいのですが、プログラムがクラッシュし、次のエラーが発生します。
"""-[__NSCFString text]: unrecognized selector sent to instance 0x861c2f0"""
このコードを確認し、考えられる解決策を教えてください...
ありがとうございました...
for ( x = 0; x < TextViewArray.count; x++)
{
// here TextViewArray is a NSMutableArray
UITextView *textField1 = [TextViewArray objectAtIndex:x];
float diff3;
diff3 = [textField1.text floatValue]; // The program crashes in this line ,"""""" -[__NSCFString text]: unrecognized selector sent to instance 0x861c2f0""""" , here I am checking for a float value but i want to use string value instead of float value in this line how to do this?
NSLog(@"diff3 is %f",diff3);
textField1.text = [[NSString alloc] initWithFormat:@"%.2f",diff3];
TXT_First_Tag = [TextViewArray objectAtIndex:x]; // here uitextview *TXT_First_Tag;
NSLog(@"txt3 is %d",x);
TXT_First_Tag.tag = x;
NSLog(@" p is %d", x);
//textField1.text = [[NSString alloc] initWithFormat:@"%.2f",diff2];
//NSLog(@"Diff is %f",diff2);
}