i have a .png image that i am trying to display as a UIBarButtonItem . Here is the sintax :
_gotoButton = [[UIBarButtonItem alloc] initWithImage:[UIImage imageNamed:@"btn_info.png"]
style:UIBarButtonItemStylePlain
target:self action:@selector(gotoAction)];
The thing is that when i try to display this image, in its place, there’s a white rectangular the size of the photo.
The odd thing is that when i try to load other images, it works.
My first thought was that the format is incorrect, but then i used an on-line convertor and it still doesn’t work. What could be the problem?
You might need to create a custom button with image on it and use the initWithCustomView: method of barbuttonitem..