I added a UIToolBar to a UIViewController and added UIBarButton in it, and also added code for display image in background but image is not displayed
here is my code
UIBarButtonItem *b1=[[UIBarButtonItem alloc]initWithTitle:@" Home " style:UIBarButtonItemStyleBordered target:self action:@selector(home: )];
[b1 setImage:[UIImage imageNamed:@"b1image.png"]];
UIBarButtonItem *b3=[[ UIBarButtonItem alloc]initWithTitle:@" WorkOuts " style:UIBarButtonItemStyleBordered target:self action:nil];
[b1 setImage:[UIImage imageNamed:@"b3image.png"]];
UIBarButtonItem *b4=[[UIBarButtonItem alloc]initWithTitle:@" All Exercises " style:UIBarButtonItemStyleBordered target:self action:@selector(all:)];
[b1 setImage:[UIImage imageNamed:@"b4image.png"]];
NSArray *li=[[NSArray alloc]initWithObjects:b1,b3,b4, nil];
self.toolBar.items=li;