TableViewCategory *detailViewController = [[TableViewCategory alloc] initWithNibName:@"TableViewCategory" bundle:nil];
    
    detailViewController.delegate = self;

//Allocing and initializing popover with table view controller.  
    popover = [[UIPopoverController alloc]
                                    initWithContentViewController:detailViewController];
    
    popover.popoverContentSize = CGSizeMake(300, 300);
    popover.delegate = self;
    [detailViewController release];
    
    [popover presentPopoverFromRect:CGRectMake(440, 350, 1, 1)
                             inView:self.view permittedArrowDirections:UIPopoverArrowDirectionUp
                           animated:YES];

Filed under: Objective C

Like this post? Subscribe to my RSS feed and get loads more!