Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

sspbond007

macrumors member
Original poster
Aug 19, 2008
46
0
Hi,

I'm drawing graph in method drawRect of UIView. This view is set to view of TabBarButton.Whenever this tab is opened it perfectly draws and display graph, but I need that,at some button click the view redraws the graph if there are some changes in record.
I tried this by calling drawRect method again, the executed with new records but the graph didn't change accordingly.
please somebody help me out, how to recall the drawRect method or refresh the graph???

Thanx
 
Never call drawRect: yourself. That is called automatically when your view needs drawing. To make your view redraw use
Code:
[view setNeedsDisplay];
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.