OSName Property

 

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 the version of the OS.

 

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 SetExtProperties. 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.

 

Example of basic property usage (recommended):

<% set bhObj = Server.CreateObject("cyScape.browserObj")

response.write "Your OS name is: " & bhObj.OSName

%>

 

 

Example of extended property usage:

<% set bhObj = Server.CreateObject("cyScape.browserObj")

bhObj.SetExtProperties "OSName"

bhObj.GetExtPropertiesEx

response.write "Your OS name is: " & bhObj.OSName

%>

 

Note: You must call the GetExtPropertiesEx method before checking the value of this property if you use the extended property form. This property requires the Enterprise Edition of BrowserHawk.

 

Special notes for this property - applies only if using the extended property version of this property (does not apply to basic version of this property):

 

See Also:

Detecting Operating System Details

Additional Steps Required for Java based properties (for extended property testing only)

OSVersion Property

OSDetails Property

OSBitSize Property

BrowserBitSize Property