November Happy Hour will be moved to Thursday December 5th.

Per Nergård
Dec 14, 2013
  2197
(0 votes)

Get a list of all display resolutions

Recently I needed to get a list of all display resolutions. I couldn’t find any info about it so I struggled a bit. This post is a note to self if I ever need to do it again. Hopefully it can be of use for someone else.

private IEnumerable<IDisplayResolution> GetDisplayResolutions()
{
  ServiceLocationHelper helper = new ServiceLocationHelper(ServiceLocator.Current);
  DisplayResolutionService resolutionservice =      helper.Advanced.GetInstance<DisplayResolutionService>();
   return resolutionservice.Resolutions;
}
Dec 14, 2013

Comments

Please login to comment.
Latest blogs
Optimizely SaaS CMS + Coveo Search Page

Short on time but need a listing feature with filters, pagination, and sorting? Create a fully functional Coveo-powered search page driven by data...

Damian Smutek | Nov 21, 2024 | Syndicated blog

Optimizely SaaS CMS DAM Picker (Interim)

Simplify your Optimizely SaaS CMS workflow with the Interim DAM Picker Chrome extension. Seamlessly integrate your DAM system, streamlining asset...

Andy Blyth | Nov 21, 2024 | Syndicated blog

Optimizely CMS Roadmap

Explore Optimizely CMS's latest roadmap, packed with developer-focused updates. From SaaS speed to Visual Builder enhancements, developer tooling...

Andy Blyth | Nov 21, 2024 | Syndicated blog

Set Default Culture in Optimizely CMS 12

Take control over culture-specific operations like date and time formatting.

Tomas Hensrud Gulla | Nov 15, 2024 | Syndicated blog