开发者

How to populate UIPickerView with .plist file?

开发者 https://www.devze.com 2023-01-09 17:51 出处:网络
I want to populate one.plist files from a num开发者_C百科ber of .plist files as per the user selection .

I want to populate one.plist files from a num开发者_C百科ber of .plist files as per the user selection . How to populate UIPickerView with a .plist file ?


I don't understand your question well but here is what I guess. You may want to load data from a .plist file and then fill in the UIPickerView.

Here is a sample code for loading a .plist file:

NSString *path = [[NSBundle mainBundle] bundlePath];
NSString *finalPath = [path stringByAppendingPathComponent:@"money.plist"];
NSDictionary *plistDictionary = [[NSDictionary dictionaryWithContentsOfFile:finalPath] retain];
0

精彩评论

暂无评论...
验证码 换一张
取 消