想在UIAlertView上显示UIProgressView [英] want to display UIProgressView on UIAlertView

查看:134
本文介绍了想在UIAlertView上显示UIProgressView的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好我想在UIAlertView上显示UIProgressView,用于显示文件上传的处理但是我搜索过多,也找到了该链接但是sill无法做到。 我不明白这一点

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 sill unable to do that. I don't get idea from this

如果有人知道最简单的方法,那么请告诉我。我会很感激。

If anyone know the easiest way to do that then please let me know. I'll be thankful.

推荐答案

试试这段代码......

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];

这篇关于想在UIAlertView上显示UIProgressView的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆