EldoS
 Table of Contents >  CallbackFilter.AddFilterDefaultRule method
Navigation
Web site
Support
Table Of Contents

CallbackFilter.AddFilterDefaultRule method

Filter:

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

CallbackFilter     See also    

Overview

This method adds an on-boot rule.

Declaration

[Pascal]
    function AddFilterDefaultRule(Mask : WideString; AccessFlag : LongWord; ProductName : AnsiString ): boolean;

[C++ (Lib)]
    bool AddFilterDefaultRule(LPCWSTR Mask, CbFltAccessFlags AccessFlag, LPSTR ProductName);

[C++ (VCL)]
    bool __fastcall AddFilterDefaultRule(WideString Mask, unsigned AccessFlag, AnsiString ProductName);

[C++ (.NET)]
    bool AddFilterDefaultRule(String^ Mask, CbFltAccessFlags AccessFlag, String^ ProductName);

[C#]
    bool AddFilterDefaultRule(String Mask, CbFltAccessFlags AccessFlag, String ProductName);

[VB.NET]
    Function AddFilterDefaultRule(ByVal Mask As String, ByVal AccessFlag As CbFltAccessFlags, ByVal ProductName as String) As Boolean

Parameters

  • Mask - mask of the files to apply filter to
  • AccessFlag - flags to be set on files that match the Mask
  • 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

[Pascal] [C++ (VCL)] [C++ (Lib)] [C++ (.NET)] [C#] [VB.NET] Value Description
fltReadOnly ReadOnly 0x00000001L The file is read-only and can not be written to or deleted.
fltWriteOnly WriteOnly 0x00000002L The file can only be written to, but not read or deleted.
fltDeleteProtect DeleteProtect 0x00000004L File deletion is not allowed.
fltClearAccessFlags ClearAccessFlags 0xFFFFFFFFL removes all access control flags

Description

Use this method to add an on-boot rule, which is used by the driver loaded during system startup.

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.

Read more about masks.

See also

DeleteFilterDefaultRule     DisableDefaultRules     GetFilterDefaultCount     GetFilterDefaultRule    

Contact Us | Terms of Use | Trademarks | Privacy Statement
Copyright (c) 1998-2011, EldoS Corporation