Table of Contents


DeviceInfo

The DeviceInfo class provides access to the device the user is using to browse the Magentrix solution.

Properties

NameDescription
NameName of the device
BrandName

Brand name of the device such as Samsung, Apple, etc.

DeviceOSUser's operating system
DeviceOSVersionUser's operating system version 
BrowserUser's browser name
IsMobileReturns true if the user's device is a mobile phone or tablet.
IsTabletReturns true if the user's device is tablet.


Note that due to the complexity of the parsing browser user-agents, there is no guarantee that the device operating system or brand name information will always be accurate. You can access the DeviceInfo class directly in ActivePage and via its provider in Active Classes.

Below is an example of accessing the DeviceInfo in an Active Class:

var deviceInfo = UserDeviceDetector.GetCurrentUserDevice();