Try our conversational search powered by Generative AI!

Using PropertyControlClassFactory.RegisterClass

I'm trying to adapt a property edit control by using PropertyControlClassFactory.Instance.RegisterClass to register my new control. This seems to work and my control is called instead. However, what I want to do is to determine what page type the property is being edited for, and I think I should be able to do that by using the PropertyData.PageDefinitionID to get the PageDefinition object which has a PageTypeID property. But the PropertyData.PageDefinitionID is always 0. Othe properties of the PropertyData object seem to be initialized properly. Isn't it possible to do this or am I doing it wrong?
Sep 30, 2009 10:48

I think I found the problem. I'm trying to do this for one of the built-in properties, and they seem to lack the PageDefinitionID which seems fair.

Is there still a way to determine what page type the control is being loaded for?

Edit: One way (a bit ugly) is to add a dummy property to the page type and look for this property.

Edited, Sep 30, 2009 12:41

You should be able to do;


Sep 30, 2009 13:16
Seems to work, thank you!
Sep 30, 2009 13:30


Jul 21, 2010 4:36
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.