我如何使用NSLocalizedString来表示这个字符串:

[NSString stringWithFormat:@"Is “%@“ still correct for “%@“ tap “OK“ otherwise tap “Change“ to choose new contact details", individual.contactInfo, individual.name];

在以下方式使用stringWithFormat之前,使用stringWithFormat时:

[NSString stringWithFormat:@"%d %@", itemCount, NSLocalizedString(@"number of items", nil)];

推荐答案

[NSString stringWithFormat:NSLocalizedString(@"Is “%@“ still correct for “%@“ tap “OK“ otherwise tap “Change“ to choose new contact details", @"Query if parm 1 is still correct for parm 2"), individual.contactInfo, individual.name];

Objective-c相关问答推荐

如何在 Objective-C 中编写计时器?

iphone keys 串项目在应用程序卸载后仍然存在?

NSInternalInconsistencyException', reason: '试图将第 0 行插入第 0 节,但更新后第 0 节只有 0 行'

我需要在 ARC 中使用 dealloc 方法吗?

表达式不可分配 - 将浮点数分配为 Xcode 中其他两个浮点数的总和时出现问题?

AppDelegate、rootViewController 和 presentViewController

将 CSS 插入 UIWebView / WKWebView 中加载的 HTML

判断是否显示 UIAlertView

碰撞技术如何运作?

如何将当前方法的名称或签名放入 NSString?

进入编辑模式时动画自定义绘制的 UITableViewCell

从 UIImage 获取 Exif 数据 - UIImagePickerController

如何在 Objective C 中将浮点数转换为 int?

自定义 colored颜色 我的 UIActivityIndi​​catorView

如何本地化 iOS 故事板

如何更改标签栏上的非活动图标/文本 colored颜色 ?

如何将 tintColor 应用于 UIImage?

UITableView 在半透明的导航栏下

如何设置字体大小以填充 UILabel 高度?

UITableViewCell中的文本居中对齐问题