This read-only property accesses a mapping in the list of mappings.
Syntax
IMappings[.Item(From)]
Settings
From
The crawler access location in the file system where the file is located.
Remarks
Since IMappings is a collection, you need only include Item to access an IMapping object by name (see the following Example).
Example
The following example displays the mappings for the KMSampleCatalog1 catalog definition.
Option Explicit
On Error Resume Next
Dim objSearchAdmin, objBuildServer, objCatalogs, objCatalog, objMappings, objMapping
Set objSearchAdmin = CreateObject("Search.SearchAdmin.1")
Set objBuildServer = objSearchAdmin.BuildServer
Set objCatalogs = objBuildServer.BuildCatalogs
Set objCatalog = objCatalogs("KMSampleCatalog1")
Set objMappings = objCatalog.objMappings
Wscript.Echo "objCatalog " & objCatalog.Name & " maps the following:"
For Each objMapping in objMappings
Wscript.Echo objMapping.From & " to " & objMapping.To
Next
'Release objects
Set objMapping = Nothing
Set objMappings = Nothing
Set objCatalog = Nothing
Set objCatalogs = Nothing
Set objBuildServer = Nothing
Set objSearchAdmin = Nothing
See Also