Scope: IMetabaseObjectDescriptor;
The Scope property determines the area for search.
The property is set to Null by default, the search is performed over the whole repository.
Executing the example requires that the repository contains a folder with the Folder_1 identifier.
To execute the example, add a link to the Metabase system assembly.
Sub UserProc;
Var
MB: IMetabase;
MDescs: IMetabaseObjectDescriptors;
MDesc: IMetabaseObjectDescriptor;
FInfo: IMetabaseObjectFindInfo;
Begin
MB := MetabaseClass.Active;
FInfo := MB.CreateFindInfo;
FInfo.ClassId := MetabaseObjectClass.KE_CLASS_FORM;
FInfo.Scope := MB.ItemById("Folder_1");
FInfo.WholeWordsOnly := False;
MDescs := MB.Find(FInfo);
For Each MDesc In MDescs Do
Debug.WriteLine("Identifier: " + MDesc.Id + "; Name: " + MDesc.Name);
End For;
End Sub UserProc;
After executing the example the search of all forms is executed in the specified folder. Names and identifiers of the found objects are displayed in the development environment console.
See also: