获取WP7设备信息的方法
/// <summary> /// 获取软硬件信息 /// </summary> /// <returns></returns> static public string GetDeviceInfo() { string deviceName = DeviceExtendedProperties.GetValue("DeviceName").ToString(); deviceName = deviceName.Replace(" ", "-"); string manufacturer = DeviceExtendedProperties.GetValue("DeviceManufacturer").ToString(); manufacturer = manufacturer.Replace(" ", "-"); string version = System.Environment.OSVersion.ToString(); version = version.Replace(" ", "-"); string screen = string.Format("{0}*{1}", System.Windows.Application.Current.Host.Content.ActualWidth , System.Windows.Application.Current.Host.Content.ActualHeight); string netType = ""; NetworkInterfaceType net = NetworkInterface.NetworkInterfaceType; netType = net.ToString(); //:手机型号 OS系统版本 V客户端版本 S屏幕尺寸 string Tem = string.Format("D_{0}-{1} OS_{2} V_{3} S_{4} N_{5} ", manufacturer, deviceName, version, GetAppVersion(), screen, netType); return Tem; }