PDA

View Full Version : About Page control




iphonejudy
Aug 6, 2009, 07:35 AM
I used the below code for creating page control


CGRect frame = CGRectMake(0.0, 0.0, 200.0, 40.0);
UIPageControl *pageControl = [[UIPageControl alloc] initWithFrame:frame];
[pageControl addTarget:self action:@selector(action:) forControlEvents:UIControlEventTouchUpInside];
[pageControl setBackgroundColor:[UIColor clearColor]];
pageControl.numberOfPages = 10;

But the control is not visible in run time.

I designed it in design time also.It didnt visible.

Can anyone tel the solution please?



iphonejudy
Aug 6, 2009, 08:06 AM
I solved it by,

pagecontrol.backgroundColor = [UIColor grayColor];