English 中文(简体)
1. 搜索国家宇宙射线或两倍
原标题:Search a NSArray of ints or doubles

我正在使用以下<编码>NSPredicate搜索一系列的习俗物品:

NSPredicate *query = [NSPredicate predicateWithFormat:@"[%K contains[cd] %@", column, searchString];

这些阵列中包含有若干变数的习俗类别(栏具体指明了应当搜索的类别)。 但是,对于<代码>NSStrings的变量而言,有些变量是ints 或doubles,而这一代码在试图分类时坠毁。 是否有任何办法列出<代码>int或doubles?

最佳回答

This works great for the variables that are NSStrings, however, there are some that are ints or doubles, and this code crashes when it trys to sort these.

  1. 填表的代码。

  2. 坠毁后。

  3. 了解你是如何试图对照阵列来评估上游的。

如果对(1)的答复是,你正在把ts/双ble直接放在阵列中,那就赢得了工作;他们必须成为目标。 如果对(2)的答复是发给NSNumber/NSValue级的未经承认的选任人,那么你需要将标号改为“密码>[cd]。

问题回答

暂无回答




相关问题
Search field with Thickbox issue

i have a search form which is shown with Thickbox inside an iframe. the problem is.. that after i click "search" the result page is shown inside the same iframe! and i want it to be shown in the main ...

Will an incomplete google sitemap hurt my search ranking?

If I submit a sitemap.xml which does not contain all of the pages of my site, will this affect my search ranking? For example: If my sitemap only contained pages that had been created in the last ...

speeding up windows file search with C#

i made a program that search logical drives to find a specific file .if user type file name an click search button , searching begins , but i don t know how to stop searching in the middle of process....

JQuery/MVC Search Issue

I have inherited a piece of work where the entry screen shows a summary of 20 calculated variables. E.g. Var A (250), Var B (79). Clicking on any of these links takes the user to a view with a ...

Handling no results for docmd.applyfilter

I have an Access app where I use search functionality. I have a TextBox and a Search Button on the form, and it does a wildcard search of whatever the user enters in the TextBox, and displays the ...

Search by using the keyboard in a list/grid - algorithm

I need to implement a custom search in a grid and I would like to find some user interface guidelines that explain the standard way to implement it. I mean this kind of search that is initiated by ...

Embed Google/ Yahoo search into a web site or build your own

I am looking for an opinion on the whether to use Google custom search, Yahoo search builder or build my own for web projects (no more than 100 pages of content). If I should build my own - do you ...

热门标签