Windows Desktop Search not returning QueryFocusedSummary

前端 未结 2 1492
没有蜡笔的小新
没有蜡笔的小新 2021-01-14 07:15

When searching through files indexed using Windows Desktop Search, it would be nice if I could see a snippet of the text within the document that is related to the search t

2条回答
  •  隐瞒了意图╮
    2021-01-14 07:53

    A colleague of mine ran into this problem recently. QueryFocusedSummary and QueryFocusedSummaryWithFallback are indeed not accessible via OLEDB. They are, however, accessible via Shell.

    In the Windows SDK, there is a sample, $WIN_SDK/Samples/winui/shell/appplatform/ExplorerBrowserSearch, which will get you set up on using Shell functions to perform a search. From here, it should be trivial to add support for QueryFocusedSummary and QueryFocusedSummaryWithFallback via the Shell Property Keys PKEY_Search_QueryFocusedSummary and PKEY_Search_QueryFocusedSummaryWithFallback respectively.

提交回复
热议问题