Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
VARFLAGS Enumeration

VARFLAGS Enumeration

Identifies the constants that define the properties of a variable.

This enumeration has a FlagsAttribute attribute that allows a bitwise combination of its member values.

Namespace:  System.Runtime.InteropServices.ComTypes
Assemblies:   System.Runtime.InteropServices (in System.Runtime.InteropServices.dll)
  mscorlib (in mscorlib.dll)

[FlagsAttribute]
public enum VARFLAGS

Member nameDescription
Supported by Portable Class LibraryVARFLAG_FBINDABLEThe variable supports data binding.
Supported by Portable Class LibraryVARFLAG_FDEFAULTBINDThe variable is the single property that best represents the object. Only one variable in type information can have this attribute.
Supported by Portable Class LibraryVARFLAG_FDEFAULTCOLLELEMPermits an optimization in which the compiler looks for a member named "xyz" on the type of "abc". If such a member is found and is flagged as an accessor function for an element of the default collection, then a call is generated to that member function. Permitted on members in dispinterfaces and interfaces; not permitted on modules.
Supported by Portable Class LibraryVARFLAG_FDISPLAYBINDThe variable is displayed to the user as bindable. VARFLAG_FBINDABLE must also be set.
Supported by Portable Class LibraryVARFLAG_FHIDDENThe variable should not be displayed to the user in a browser, although it exists and is bindable.
Supported by Portable Class LibraryVARFLAG_FIMMEDIATEBINDThe variable is mapped as individual bindable properties.
Supported by Portable Class LibraryVARFLAG_FNONBROWSABLEThe variable appears in an object browser, but not in a properties browser.
Supported by Portable Class LibraryVARFLAG_FREADONLYAssignment to the variable should not be allowed.
Supported by Portable Class LibraryVARFLAG_FREPLACEABLETags the interface as having default behaviors.
Supported by Portable Class LibraryVARFLAG_FREQUESTEDITWhen set, any attempt to directly change the property results in a call to IPropertyNotifySink::OnRequestEdit. The implementation of OnRequestEdit determines if the change is accepted.
Supported by Portable Class LibraryVARFLAG_FRESTRICTEDThe variable should not be accessible from macro languages. This flag is intended for system-level variables or variables that you do not want type browsers to display.
Supported by Portable Class LibraryVARFLAG_FSOURCEThe variable returns an object that is a source of events.
Supported by Portable Class LibraryVARFLAG_FUIDEFAULTThe variable is the default display in the user interface.

For additional information about VARFLAGS, see the MSDN Library.

The common language runtime throws an exception when a COM method in native code returns an HRESULT. For more information, see How to: Map HRESULTs and Exceptions.

.NET Framework

Supported in: 4.6, 4.5, 4, 3.5, 3.0, 2.0

.NET Framework Client Profile

Supported in: 4, 3.5 SP1

.NET for Windows Phone apps

Supported in: Windows Phone 8.1

Portable Class Library

Supported in: Portable Class Library
Show:
© 2015 Microsoft