iphone - Performance problem when using UITextView -
i having performance issue.
i have developed app, had no problems navigation, app working smoothly. until added uitextview, when clicking button switches view view used textview, takes 4 5 seconds switch view. happens when filling textview 30-40 lines of text.
i added textview using interface builder, whiteout adding code related uitextview in xcode.
can please me solving issue ??
thanks.
edit: code page containing textview
// food.m // azkar // // created al3madi on 18/02/2011. // copyright 2011 __mycompanyname__. rights reserved. // #import "food.h" #import "mainmenuviewcontroller.h" @implementation food - (ibaction) mainmenu:(id)sender { mainmenuviewcontroller* mainm = [[mainmenuviewcontroller alloc] initwithnibname:@"mainmenuviewcontroller" bundle:nil]; [self.navigationcontroller pushviewcontroller:mainm animated:yes]; } - (void)dealloc { [mainmenuviewcontroller release]; [super dealloc]; } @end
note: have entered text in xib file using interface builder, not coding, have changed content of textview text wanted. made textview not editable.
the code in food.m textview content in food.xib
this looks bit weird. anyway, try following. instead of putting text in uitextview
using interface builder, programmatically. in view controller responsible handling uitextview
, add following line in viewdidload
method:
mytextview.text = @"your text here";
mytextview
name assigned outlet variable associated uitextview
.
Comments
Post a Comment