CallbackFilter

Instant control over file and folder operations in Windows and .NET applications

CallbackFilter.GetFilterDefaultRule method

Filter:

Pascal    C++ (Lib)    C++ (VCL)    C++ (.NET)    C#    VB.NET   

CallbackFilter     See also    

Overview

Returns the on-boot rule with the given index

Declaration

[Pascal]
    function GetFilterDefaultRule( Index : Integer; var Mask : TCBString; var AccessFlag : LongWord; ProductName : AnsiString) : boolean;
    type TCBString = {$ifdef UNICODE}UnicodeString{$else}WideString{$endif};

[C++ (Lib)]
    bool GetFilterDefaultRule( int Index, LPWSTR* Mask, CbFltAccessFlags* AccessFlag, LPCSTR ProductName);

[C++ (VCL)]
    bool __fastcall GetFilterDefaultRule( int Index, WideString &Mask, unsigned * AccessFlag, AnsiString ProductName);

[C++ (.NET)]
    bool GetFilterDefaultRule( int Index, String^%Mask, CbFltAccessFlags% AccessFlag, String^ ProductName);

[C#]
    bool GetFilterDefaultRule( int32 Index, ref string Mask, ref CbFltAccessFlags AccessFlag, string ProductName);

[VB.NET]
    Function GetFilterDefaultRule( ByVal Index As Int32, ByRef Mask As Integer, ByRef AccessFlag As CbFltAccessFlags, ByVal ProductName As String) As Boolean

Parameters

  • Index - index of the rule
  • Mask - contains mask of the files to apply the filter to
  • AccessFlag - access filter flag
  • ProductName - the name or symbolic identifier of the program that has set the rule

Return values

TRUE / true if the function succeeded or FALSE / false if the function failed.

AccessFlag values

Description

Use this method to retrieve Index'th on-boot rule from the list of on-boot rules, set by your application.

ProductName is used to distinguish the rules, set by different applications or modules. The value is used as a key in registry, so keep it short but unique. String format of GUID value works fine.

Read more about default rules.

See also

AddFilterDefaultRule     DeleteFilterDefaultRule     GetFilterDefaultCount    

Back to top