WSFromScript

The WSFromScript code sample demonstrates how to query Windows Search from a Microsoft Visual Basic script using Microsoft ActiveX Data Objects (ADO).

This topic contains the following sections.

Requirements

Product Product Version
Windows Windows 7, 8.1, or 10
Windows SDK 7.0 or greater

Downloading the Sample

This sample is available in the following location.

Location Path URL
GitHub WSFromScript sample

Note

For all versions of Windows, including Windows 7, it is recommended to download the samples directly from GitHub for the most up to date version.

Building the Sample

To build the sample from the Command Prompt window:

  1. Open the Command Prompt window and navigate to the QueryEverything project directory. For example, the full default installation path of the Windows 7 SDK is C:\Program Files\Microsoft SDKs\Windows\v7.0\Samples\WinUI\WindowsSearch\WSFromScript.
  2. Enter cscript QueryEverything.vbs.

Conceptual

VBScript Language Reference

Other Samples

Search Code Samples