| David @ WSDOT 2006-03-21, 8:47 pm |
| Hi,
I am using ASP.NET 2.0 with CMS 2002 SP2. I have a UserControl that
contains two PlaceHolderControl. I have a properties of the UserControl to
set the PlaceHolderControls' PlaceHolderToBind property:
public string HtmlPlaceholderToBind
{
get { return HtmlControl.PlaceholderToBind; }
set { HtmlControl.PlaceholderToBind = value; }
}
public string ImagePlaceholderToBind
{
get { return ImageControl.PlaceholderToBind; }
set { ImageControl.PlaceholderToBind = value; }
}
This works very well.
What I'd like to do is use the PlaceholderNameEditor
(Microsoft.ContentManagement.WebControls.Design) so the property will
function just like it were a property of a PlaceholderControl. Like so:
using System.Drawing.Design;
using Microsoft.ContentManagement.WebControls.Design;
& #91;EditorAttribute(typeof(PlaceholderNa
meEditor), typeof(UITypeEditor))]
public string ImagePlaceholderToBind
{
get { return ImageControl.PlaceholderToBind; }
set { ImageControl.PlaceholderToBind = value; }
}
The Designer (Visual Studio) doesn't seem to recognize this and treats the
property like it was simply a text property. Am I missing something? How
should this be implamented?
David
|