New Search APIs

Hello,


Has anybody been able to get their indexed search items to show up in the new iOS 9 search page? I'm building up my search index using the NSUserActivity using the following steps.


1. Create NSUserActivity object. I'm using the reverse DNS name to make the index unique.

2. Set the title and keyword properties on the NSUserActivity object. I didn't set the contentAttributes proeprty yet since I wasn't able to find the contentAttribute properties in the iOS 9 documents.

3. Set the eligibleForSearch, eligibleForPublicIndex and eligibleForHandoff properties to true on the NSUserActivity object

4. Called the becomeCurrent method on the NSUserActivity object.

5. Closed the application and went to the new Search page in iOS 9.


When I typed the title of the index in step #2 nothing was found.


Thanks in advanced!

Hi,


I'm running into the same exact thing.... wondering if this is functional in beta 1.

Are you trying this on the simulator or on the device?

Also tried this (on the device as recommended somewhere) and it didn't work. I just get no results at all. Even tried rebooting the device to no avail.

I've had the same issue with NSUserActivity not appearing in the Spotlight search, both in Simulator and on Device (both iPad Air and iPhone 6+)

I have the same issue, wish Apple employee could help.

I also try the CoreSpotlight way, both thumbnailData and thumbnailURL on CSSearchableItemAttributeSet don't work for displaying a thumbnail image

NSUserActivity is not working for me, but CoreSpotlight works.


Thumbnail images are working with beta 2

Beta 1:

- NSUSerActivity was working, but title only. Thumbnail and description were not showing up.

- CoreSpotlight was working, but title and description only. Thumbnail was not showing up.


Beta 2:

- NSUSerActivity not working at all.

- CoreSpotlight working. Thumbnail working too.

Moving this discussion to the Spotlight forum. There are a couple other posts about problems getting NSUserActivity to work in seed 1, you can search the Spotlight forum for some more details. It does appear that NSUserActivity is not working as expected in the 2nd seed update. CoreSpotlight should be working, though.


Certainly if you're unable to get something to work, please file bug reports. That's the official way of letting Apple know that something isn't working right for you. Including bug numbers in forum posts helps us connect the dots and get more information so please do post any bug numbers here.

New Search APIs
 
 
Q