- enumVal
A System.Windows.Forms.SystemParameter representing the feature to search for.
![]()
true if the feature is available on the system; otherwise, false.
Typically, you use the OSFeature.IsPresent(SystemParameter) method to determine if the operating system supports the specific feature or metric identified by enumValue. Based upon the value returned from OSFeature.IsPresent(SystemParameter), you would perform conditional actions in your code. For example, if calling this method with a parameter value of SystemParameter.FlatMenu returns true, you could create owner-drawn menus in your application in a flat style.
Accessing some system features or metrics can raise exceptions if they are not available on a specific operating system version. In this case, first use the corresponding System.Windows.Forms.SystemParameter enumeration value, along with OSFeature.IsPresent(SystemParameter), to determine if the metric is supported. For example, call OSFeature.IsPresent(SystemParameter) with SystemInformation.CaretWidth before getting the SystemInformation.CaretWidth property value.