DataAbstraction and PageTypeAvailability



From 7.5 I am not able to get a setting this way. PageTypeAvailability is still there, but AvailableSetting is not. Anybody knows other way to get it or where is it moved?

var setting = new EPiServer.DataAbstraction.PageTypeAvailability.AvailableSetting();


Jan 04, 2014 21:50

Try this:

var service = ServiceLocator.Current.GetInstance<IAvailableContentTypes>();
AvailableSetting settings = service.GetSetting(/*ContentType name*/Name);



var repository  = ServiceLocator.Current.GetInstance<IContentTypeRepository>();
var allSettings = repository.ListSettings();


Hope that help!

// Ha Bui

Jan 06, 2014 3:39

Thank you Ha! It works.

Jan 08, 2014 12:22
This topic was created over six months ago and has been resolved. If you have a similar question, please create a new topic and refer to this one.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.