Failure when adding images to a thumbnail gallery

Posted by Martin KS on Stack Overflow See other posts from Stack Overflow or by Martin KS
Published on 2010-04-20T19:56:30Z Indexed on 2010/04/20 20:03 UTC
Read the original article Hit count: 177

Filed under:
|
|

morning all, I've been browsing around trying to work out what I've done wrong when trying to add a thumbnail to a gallery view, but can't work out what on earth it might be. I'm trying to use the following code to stick a thumbnail onto a blank view:

UIImageView *any = [[UIImageView alloc] initWithFrame:CGRectMake(a,b,70,60)];
any.image = [UIImage imageNamed:selectedThumbPath];
any.tag = 0;
[self.view addSubview:any];

In the above example:

a = 165
b = 150
selectedThumbPath = the full path to a thumbnail ie. /users/Cleverbum/library etc

I'm pulling my hair out, there are no error messages, and no clues as to why it's not drawing anything. What's worse is that this is one of the only parts of the code i've not changed!

© Stack Overflow or respective owner

Related posts about iphone

Related posts about uiimageview