Contents

Develop
2013.04.23 18:08

[ios] 디렉토리 하하하..

Views 33514 Comment 0
?

Shortcut

PrevPrev Article

NextNext Article

Larger Font Smaller Font Up Down Go comment Print
?

Shortcut

PrevPrev Article

NextNext Article

Larger Font Smaller Font Up Down Go comment Print

디렉토리 탐색하는 샘플 코드~

NSString *newDir;
if( parent_dir > 0 ){
    newDir = [NSString stringWithFormat:@"NToon/%d", parent_dir];
}else{
    newDir = @"NToon";
}

NSString *newPath = [documentsDirectory stringByAppendingPathComponent:newDir];

if (![fileManager fileExistsAtPath:newPath]) {
    if ([fileManager createDirectoryAtPath:newPath withIntermediateDirectories:YES attributes:nil error:&error]) {
        //NSLog(@"getDBFilePath: %@ created.", newPath);
    } else {
        NSLog(@"getDBFilePath: Failed to create %@ due to %@", newPath, error);
    }
}

?

List of Articles
No. Category Subject Author Date Views
435 Develop [linux] 프로세스 관련 시스템콜 hooni 2003.04.23 9248
434 Develop [c] 스토리지 클래스(변수) hooni 2003.04.23 9245
433 Develop 다양한 방법으로 아주 큰 수(Big Number) 계산.. ㅋㅋ hooni 2013.04.23 9241
432 Develop [c] GD라이브러리 설치 테스트 소스 file hooni 2013.04.23 9238
431 Develop [java] RGB코드를 HEX코드로 변환하는 코드 ㅎㅎ hooni 2013.04.23 9229
430 Develop [js] 셀렉트박스(select)의 옵션(option) 동적으로 추가/제거 file hooni 2013.04.23 9228
429 Develop [c] 구구단 최단라인 ㅡㅡ; file hooni 2013.04.23 9225
428 Develop [js] 핫키(단축키) 구현방법 hooni 2003.04.23 9223
427 Develop [c] 퀵정렬(quick sort) 예제 소스.. file hooni 2013.04.23 9222
426 Develop [c] 포인터와 함수포인터에 대해.. hooni 2003.04.23 9211
425 Develop [c++] Win32API를 이용한 ExitWindowsEx 사용한 예제코드 hooni 2013.04.23 9206
424 Develop [c] 단기과정[01/08] (다차원 + 배열)포인터, void 포인터 hooni 2003.04.23 9203
Board Pagination Prev 1 ... 30 31 32 33 34 35 36 37 38 39 ... 71 Next
/ 71