Try our conversational search powered by Generative AI!

Moving project from CMS 8.11 to 10 -- DataFactory.Instance.CreatingPage and Category.Find



I am in the process of moving our site from 8.11 to 10. Everything is more or less going okay. I was able to successfully upgrade to 9, and then when I upgraded to 10 I got some compilation errors. I was expecting this, and I have been replacing apis that are now gone with the newer ones.

The problem right now is that I am having problems finding how to replace two apis.

The first one is those that are connected with Page creation events, things like this one


The second one has to do with querynig Categories like this:


What are the objects that I should use for this two cases?

Thanks in advance.

Oct 05, 2017 20:36


var contentEvents = ServiceLocator.Current.GetInstance<IContentEvents>();

contentEvents.CreatingPage += YourMethod()


var categoryRepository = ServiceLocator.Current.GetInstance<CategoryRepository>();

Oct 06, 2017 13:34
<p>Thanks so much!</p>
Oct 16, 2017 15:53
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.