-1
我突然從我的一個類中得到一個錯誤。 錯誤是多種方法命名爲boolValue
Multiple methods named 'boolValue' found with mismatched result, type or attributes.
這裏是代碼得到的錯誤,
[cell2.LBL_Detail setHidden:[[mArr_isAnswered objectAtIndex:[indexPath row]]boolValue]];
和
BOOL detailed = [[mArr_isAnswered objectAtIndex:selectedIndex] boolValue];
你能否解釋一下是什麼問題?
用這個'boolValue'方法發佈類的'@ interface'。 – trojanfoe
您是否使用名爲boolValue的方法創建了類?此方法已經存在於Apple框架中,因此您不應將此名稱用於自定義方法。你在mArr_isAnswered數組中存儲什麼對象? – Greg
1.我沒有用boolValue創建一個類。 2.我將原始的BOOL類型數據存儲在數組中。 ...我已經使用搜索在我的方法名稱中檢查了BoolValue的用法。 – user2228755