views:

26

answers:

1

hi all. i have a problem with the uibuttons . i cant scale image to fit their frame . please any advice

A: 
UIButton *Btn = [UIButton buttonWithType:UIButtonTypeCustom];
    Btn.frame = //set frame using CGRectMake(x,y,width,height);     
    [Btn setBackgroundImage:[UIImage imageNamed:@"image name here"] forState:UIControlStateNormal];
Matrix
^^ it's a little late ive found the solution I needed to combine setbackgroundimage and set to fill
zdali