want to display UIProgressView on UIAlertView

前端 未结 6 378
挽巷
挽巷 2021-01-03 07:45

Hi guys i want to display UIProgressView on UIAlertView for displaying the processing of uploading of the file but i have searched too much and also find on that link but si

6条回答
  •  离开以前
    2021-01-03 07:55

    Try this code...

    UIAlertView *av = [[UIAlertView alloc] initWithTitle:@"" message:@"" delegate:nil cancelButtonTitle:nil otherButtonTitles:nil];
    UIProgressView *pv = [[UIProgressView alloc] initWithProgressViewStyle:UIProgressViewStyleBar];
    pv.frame = CGRectMake(20, 20, 200, 15);
    pv.progress = 0.5;
    [av addSubview:pv];
    [av show];
    

提交回复
热议问题