What you need is UIScrollView with pagination. It works essentially the same way a standard UITable does. When you scroll from left to right you just push new "cells" on the stack and present them.
Here is a sample code:
// .h File
@interface PagingViewController : UIViewController <UIScrollViewDelegate>{
NSMutableArray *cells;
}
@property(nonatomic,retain)NSMutableArray *cells;
-(id)initWithCells:(NSMutableArray*)tableCells;
-(void)loadPage:(int)page;
@end
// .m File
@interface PagingViewController ()
@property(nonatomic,retain)NSMutableArray *viewControllers;
@property(nonatomic,retain)UIView *contentView;
@property(nonatomic,readwrite)NSUInteger numberOfPages;
@end
@implementation PagingViewController
@synthesize viewControllers;
@synthesize contentView;
@synthesize cells;
@synthesize numberOfPages;
-(id)initWithCells:(NSMutableArray*)tableCells{
self = [super init];
if(self) {
self.cells = tableCells;
numberOfPages = [cells count];
NSMutableArray *controllers = [[NSMutableArray alloc] init];
for (unsigned i = 0; i < numberOfPages; i++)
{
[controllers addObject:[NSNull null]];
}
self.viewControllers = controllers;
[controllers release];
contentView = [[UIView alloc] initWithFrame:CGRectMake(0, 0, 320, 480)];
self.view = contentView;
[self loadPage:0];
}
return self;
}
- (void)loadPage:(int)page{
if (page < 0)
return;
if (page >= kNumberOfPages)
return;
else if(page > 0){
CustomCellVC *cell = [viewControllers objectAtIndex:page];
if ((NSNull *)cell == [NSNull null]){
cell = (CustomCellVC*)[cells objectAtIndex:page];
[viewControllers replaceObjectAtIndex:page withObject:cell;
[cell release];
}
if (cell.view.superview == nil)
{
[contentView addSubview:cell.view];
}
}
}
//Dont forget to dealloc.
I wrote this from memory so there might be little bugz.