2012-10-02 3 views

답변

4

만약에 의해 당신은 그것을 (0 바이트)에 절대적으로 아무 것도이 같은 것을 할 수 없습니다 의미 "빈"

NSFileManager *manager = [NSFileManager defaultManager]; 
if ([manager fileExistsAtPath:path]) { 
    NSDictionary *attributes = [manager attributesOfItemAtPath:path error:nil]; 
    unsigned long long size = [attributes fileSize]; 
    if (attributes && size == 0) { 
     // file exists, but is empty. 
    } 
} 
+0

경로 변수가 여기에 무엇입니까? – dcprog

+0

파일의 경로입니다. – DrummerB

관련 문제