I am creating a Wizard Control in C# application. So, I have created two classes XWizardControl and XWinzardPage . The collection of XWizardPage will be created in XWizardControl. User can manually add number of XWizardPage in XWizardControl just like TabPage in TabControl. My problem is developer cannot use that XWizardPage control directly in any other container or form. They cannot add directly into any container. But they can create object from the editor and it should not be displayed in my ToolBox. So, I am confused in what attribute should i use to hide that PageControl in ToolBox and how to avoid user to add that control into any other container control.
Class Declaration as Follows: I don't want to make you confused. So, I am just placing declaration.
//Main Control
public partial class XWizardControl : DevExpress.XtraEditors.XtraUserControl
{
public XWizardPageCollection Pages
{ get; set; }
}
//Collection of WizardPage
class XWizardPageCollection : IEnumerable<XWizardPage>, ICollection<XWizardPage>
//Wizard Page
public partial class XWizardPage : DevExpress.XtraEditors.XtraPanel, IComparable<XWizardPage>
{
//Some Properties
public XWizardPage() //Contructor
}
If you need more specification then please tell me. I will edit my question give that detail in UPDATE:
You can provide solution in VB also.