OSName Property (.NET)

 

Type: String

 

OSName returns the general name of the user's operating system, such as "Windows", "OS X", and "Linux".  For example, the OSName property is set to "Windows" for all users on Windows XP, Windows Vista, Windows 8 and so forth, and the OSName property is set to "OS X" for all Mac users on OS X.  Therefore this property makes it easy to determine if a user is on Windows, OS X, Linux and other operating systems without regards to the version of the OS.

 

This is the extended property version of OSName. Starting with BrowserHawk 14, the OSName property can be checked as a basic property, so an extended property test is no longer required. If you previously used this property as an extended property, simply remove "OSName" from the list of properties specified in your call to AddProperties and use this OSName property from the BrowserObj class instead of from the ExtendedBrowserObj class. There is no advantage to testing OSName as an extended property for users on Windows and OS X.  For users on other operating systems, such as Linux, some additional details may be provided through the extended property version.  Unless that is highly desirable, the basic property version of OSName will provide for much faster testing by BrowserHawk.

 

Tip: See Detecting Operating System Details for examples of the possible values returned by this property.

 

Special notes for this property:

 

Note: Use of this property requires the Enterprise Edition of BrowserHawk.

 

C# Example:

<%

ExtendedOptions options = new ExtendedOptions();

options.AddProperties("OSName");

ExtendedBrowserObj extBrow = BrowserObj.GetExtendedBrowser(options);

%>

<html>OSName is: <% Response.Write(extBrow.OSName);  %>

</html>

 

 

See Also:

Detecting Operating System Details

Additional Steps Required for Java based properties

OSVersion Property (.NET)

OSBitSize Property (.NET)

BrowserBitSize Property (.NET)