小编Jig*_*tel的帖子

从IOS 8在UIActionSheet中添加UIPickerView无法正常工作

我正在补充UIPickerView,UIActionsheet但它的工作完美,ios 7但没有工作ios 8.请帮我解决这个问题.

在这里我附上了截图.在此输入图像描述

谢谢

我正在使用以下代码.

UIActionSheet *actionSheet;
NSString *pickerType;

- (void)createActionSheet {

    if (actionSheet == nil) {
        // setup actionsheet to contain the UIPicker
        actionSheet = [[UIActionSheet alloc] initWithTitle:@"Please select" delegate:self cancelButtonTitle:nil destructiveButtonTitle:nil otherButtonTitles:nil];
        actionSheet.backgroundColor = [UIColor clearColor];

        UIToolbar *pickerToolbar = [[UIToolbar alloc] initWithFrame:CGRectMake(0, 0, 320, 40)];
        pickerToolbar.barStyle = UIBarStyleBlackOpaque;
        [pickerToolbar sizeToFit];

        UIImageView *imageObj = [[UIImageView alloc]initWithFrame:CGRectMake(0, 0, 320, 40)];
        imageObj.image = [UIImage imageNamed:@"header.png"];
        [pickerToolbar addSubview:imageObj];

        UIButton *cancelBtn = [UIButton buttonWithType:UIButtonTypeCustom]; …
Run Code Online (Sandbox Code Playgroud)

iphone uipickerview uiactionsheet ios ios8

52
推荐指数
4
解决办法
3万
查看次数

如何检查iOS 7中的特定应用是否启用了位置服务?

我想检查Location Service是否on/off适用于我的应用程序,因为当我转向locaiton Service to ON但是application service is off如何?我如何通过代码检查它.

请帮忙解决我的问题.

提前致谢.

location dictionary ios ios7

4
推荐指数
2
解决办法
4477
查看次数

标签 统计

ios ×2

dictionary ×1

ios7 ×1

ios8 ×1

iphone ×1

location ×1

uiactionsheet ×1

uipickerview ×1