2018. 12. 12. 18:41 아이폰

담당자가 퇴사한 프로젝트를 ad hoc 으로 배포할려고 컴파일을 하는데 에러가 났다.

어떻게 해서 컴파일 완료 하고 배포가 되었따 어느 순서에서 수정된건지 몰라 작업 내용을 적어 둔다.

마지막에 한 작업이 결정적이었다.


에러 내용 - Doesn't match entitlements file value for application-identifier


에러 내용 - Profile doesn't match the entitlements file's value for the application-identifier entitlement

에러 내용  - Automatic signing is unable to resolve an issue with the "***.app" target's entitlements.

Switch to manual signing and resolve the issue by downloading a matching provisioning profile from the developer website. Alternatively, to continue using automatic signing, remove these entitlements from your entitlements file and their associated functionality from your code. Then rebuild your archive and try again.



build setting 쪽을 확인해서

bundle identifier 에 com.domain.appname 으로 변경을 시도했다 

그래도 안된다 


도메인이 들어가야될 부분에 컴퓨터 이름이 들어간 부분들을 다수정한다 .

Sons.*** 이런 것들을 com.domain.appanme.*** 으로 수정해도 안된다 


https://developer.apple.com/account/ios/certificate/ 접속해 안쓰는 프로파일들을 다지고 

새로 만든다 (지운다고 서비스 안되는건 아니니깐)


그리고 마지막으로 폴더 이동을 한다 


~/Library/MobileDevice/Provisioning Profiles


싹다 지운다 그리고 다시하면 adhoc 컴파일이 완료된다 


제발 도움이 되길 바란다.




posted by 욱이다
2018. 6. 12. 16:24 아이폰

안드로이드 fromHtml 기능을 iOS에서 사용하자 (NSMutableAttributedString)

폰트 종류와 사이즈도 설정이 가능하다


self.popupDesc.attributedText = [UTIL  getHtmlString:desc fontSize:17];



-(NSMutableAttributedString *)getHtmlString:(NSString *) str fontSize:(CGFloat) size

{

    NSMutableAttributedString *attrString= [[NSMutableAttributedString alloc] initWithData:[str dataUsingEncoding:NSUnicodeStringEncoding]

                                                                                   options:@{NSDocumentTypeDocumentAttribute: NSHTMLTextDocumentType,                                NSCharacterEncodingDocumentAttribute: [NSNumber numberWithInt:NSUTF8StringEncoding]

                                                                                             }

                                                                        documentAttributes:nil error:nil];

    [attrString beginEditing];

    [attrString enumerateAttribute:NSFontAttributeName inRange:NSMakeRange(0, attrString.length) options:0 usingBlock:^(id value, NSRange range, BOOL *stop) {

        

        UIFont* font = value;

        font = [UIFont fontWithName:@"AppleSDGothicNeo-Regular" size:size];

        

        [attrString removeAttribute:NSFontAttributeName range:range];

        [attrString addAttribute:NSFontAttributeName value:font range:range];

    }];

    

    [attrString endEditing];

    return attrString;

}


posted by 욱이다
2015. 8. 26. 23:52 아이폰

카카오 로그인 방법은 너무 잘 나와있따 


여기 사이트에 

https://developers.kakao.com/docs/ios



하다 보니 이게 맞나 싶은것도 샘플을 다운 받아 확인하면 쉽게 된다 

3년전만해도 카카오톡에 업무협약 맺고 이거 주니 마니 저장하면 안되니 마니 그랬었는데 ...

요즘은 사이트에 클릭 띡띡띡 하니깐 끝이네 ...


그래도 예전에는 아이디 인덱스 값도 줬는데 인제 안주네 ..




하다 보니 NSAppTransportSecurity ,,, NSExceptionDomains  ...이런거  어디서 하나 했는데 plist파일 열어서 추가해 주면된다 



또 KAKAO_APP_KEY 에 들어갈 값은 카카오사이트에 등록한 네이티브 앱 키다 


예제에 나온 모든 0123456789.........이건  본인이 등록한 네이티브 앱 키 로 치환해서 사용한다고 생각 하면된다 


posted by 욱이다
2015. 4. 9. 13:28 아이폰

아이폰 디폴트 공유 사용 방법 


NSArray *items 

= [[NSArray alloc]initWithObjects:@"array",@"string",[UIImage imageNamed:@"icon_50.png"], nil];

UIActivityViewController *activityViewController 

= [[UIActivityViewController alloc] initWithActivityItems:items applicationActivities:nil];

activityViewController.completionHandler = ^(NSString *activityType, BOOL completed) {

        NSLog(@"shared completed");

};

[self presentViewController:activityViewController animated:YES completion:nil];




안드로이드 디폴트 공유 사용방법은 



Intent share = new Intent(android.content.Intent.ACTION_SEND);

share.setType("text/plain");////text/* 이걸로 하면 facebook 공유 안됨 

share.putExtra(Intent.EXTRA_TEXT, URLDecoder.decode(str));

mActivity.startActivity(Intent.createChooser(share, "공유"));

posted by 욱이다
2014. 11. 18. 18:11 아이폰

ios 오토 포커스 기능 체크 하는 소스 




NSArray *devices = [AVCaptureDevice devices];

    AVCaptureDevice *frontCamera;

    AVCaptureDevice *backCamera;

    

    for (AVCaptureDevice *device in devices) {

        

        DEBUGMSG(@"Device name: %@", [device localizedName]);

     

        if ([device hasMediaType:AVMediaTypeVideo]) {

            

            if ([device position] == AVCaptureDevicePositionBack) {

                DEBUGMSG(@"Device position : back");

                backCamera = device;

            }

            else {

                DEBUGMSG(@"Device position : front");

                frontCamera = device;

            }

        }

    }

    

    if([backCamera isFocusModeSupported:AVCaptureFocusModeAutoFocus])

    {

        

    }else

    {

        UIAlertView *alert = [[UIAlertView alloc] initWithTitle:nil

                                                        message:@"오토 포커스 기능이 ."

                                                       delegate:nil

                                              cancelButtonTitle:@"ok"

                                            otherButtonTitles:nil];

        [alert show];


    }

    

posted by 욱이다
2014. 1. 3. 15:43 아이폰

포문으로 계속해서 한 함수만 호출할때 

아래와 같은방법을 선언하고 포문에서 함수호출을 하는 방법이 다른 어떤 방법 보다 

심지어 직접 연산을 넣거나 직접 함수를 호출하는 부분 보다 속도가 빠르다고 한다 ...

파라메터가 없을 경우만일거 같은데 .. 책에서는 

파라메터 없는 함수 호출의 경우에서 말했다 

책 objective-c 3판 224페이지 표 8-1


앞으로 무한으로 도는 함수호출의 경우 아래의 경우를 애용해야겠다

1.tydef 선언한경우


typedef int (*f) (id,SEL,int,int);

        f fPoint;

        fPoint = (int(*)(id,SEL,int,int))[self methodForSelector:@selector(testFunctionPoint:B:)];

        NSLog(@"%d",(*fPoint)(self ,@selector(testFunctionPoint:B:),1,2));

2.그냥 사용인 경우

int (*fPoint)(id,SEL,int,int);

        fPoint = (int(*)(id,SEL,int,int))[self methodForSelector:@selector(testFunctionPoint:B:)];

        NSLog(@"%d",(*fPoint)(self ,@selector(testFunctionPoint:B:),1,2));



-(int)testFunctionPoint:(int)a B:(int)b

{

    return a+b;

}

'아이폰' 카테고리의 다른 글

ios 텍스트 이미지 디폴트 공유 - ios shared text image  (0) 2015.04.09
ios auto focus check  (0) 2014.11.18
앱에서 이미지 동영상 겔러리로 저장  (0) 2013.10.28
ios custom keyboard  (0) 2013.06.12
ios arc mrc 설정하기  (0) 2013.03.26
posted by 욱이다
2013. 10. 28. 15:53 아이폰


앱에서 이미지 겔러리로 저장

-(void)saveImageatAlbum:(UIImage *)img

{

    //이미지 저장

    [loadingView startLoading];

    UIImageWriteToSavedPhotosAlbum(img, self, @selector(image:didFinishSavingWithError:contextInfo:), nil);

    

}

- (void) image:(UIImage*)image didFinishSavingWithError:(NSError *)error contextInfo:(NSDictionary*)info

{

    [loadingView endLoading];

    if(error == nil)

    {

        [mCp setPopUpSimple:LOCSTRING("이미지 저장 성공!")];

    }else

    {

        [mCp setPopUpSimple:LOCSTRING("이미지 저장 실패!")];

    }

}


앱에서보는 동영상 겔러리로 저장

- (void) downloadVideo:(NSString *)url

{

    //동영상 저장

    [loadingView startLoading];

    

    [self performSelectorOnMainThread:@selector(downloadVideoGo:) withObject:url waitUntilDone:NO];

}

-(void)downloadVideoGo:(NSString *)url

{

    NSData *imageData = [NSData dataWithContentsOfURL:[NSURL URLWithString:url]];

    NSString *tempPath = [NSString stringWithFormat:@"%@temp.mp4", NSTemporaryDirectory()];

    [imageData writeToFile:tempPath atomically:NO];

    UISaveVideoAtPathToSavedPhotosAlbum (tempPath, self, @selector(video:didFinishSavingWithError: contextInfo:), nil);

}

- (void) video: (NSString *) videoPath didFinishSavingWithError:(NSError *)error  contextInfo:(void *)contextInfo

{

    [loadingView endLoading];

    if(error == nil)

    {

        [mCp setPopUpSimple:LOCSTRING("동영상 저장 성공!")];

    }else

    {

        [mCp setPopUpSimple:LOCSTRING("동영상 저장 실패!")];

    }

    

}


IOS SAVE GALLERY APP IMAGE AND VIDEO

'아이폰' 카테고리의 다른 글

ios auto focus check  (0) 2014.11.18
objective-c 함수포인터를 사용한 함수 호출  (0) 2014.01.03
ios custom keyboard  (0) 2013.06.12
ios arc mrc 설정하기  (0) 2013.03.26
ios gridview  (0) 2013.03.22
posted by 욱이다
2013. 6. 12. 10:11 아이폰


CustomInputViewDemo-master.zip

http://blog.carbonfive.com/2012/03/12/customizing-the-ios-keyboard/


커스텀 키패드 좋네 


'아이폰' 카테고리의 다른 글

objective-c 함수포인터를 사용한 함수 호출  (0) 2014.01.03
앱에서 이미지 동영상 겔러리로 저장  (0) 2013.10.28
ios arc mrc 설정하기  (0) 2013.03.26
ios gridview  (0) 2013.03.22
NSString encoding decoding  (0) 2013.03.22
posted by 욱이다
2013. 3. 26. 15:36 아이폰
http://blog.naver.com/solarin4314?Redirect=Log&logNo=50161892672

http://j2enty.com/102



위의 두 블로그 보면 

arc mrc 설정하는 방법이있다 


프로젝트 초반에 설정하는 방법

프로젝트에서 설정하는 방법

소스별로 설정하는 방법

-fobjc-arc


-fno-objc-arc

'아이폰' 카테고리의 다른 글

앱에서 이미지 동영상 겔러리로 저장  (0) 2013.10.28
ios custom keyboard  (0) 2013.06.12
ios gridview  (0) 2013.03.22
NSString encoding decoding  (0) 2013.03.22
Ios NSArray 에 NSArray 더하기  (0) 2013.03.22
posted by 욱이다
2013. 3. 22. 19:22 아이폰

출처

https://github.com/gmoledina/GMGridView

GMGridView-master 2.zip


posted by 욱이다
prev 1 2 3 4 next