protected void Page_Load(object sender, System.EventArgs e)
        {
            prnt = (BasePages.BasePage) this.Page;
            // Setup tab 1
            setupGeneralInfoTab();
            setupTabTab();
            setupGenericPropertyTypesTab();

            AllowedContentTypes               = new ListBox();
            AllowedContentTypes.ID            = "AllowedContentTypes";
            AllowedContentTypes.SelectionMode = ListSelectionMode.Multiple;


            int[] allowedIds = docType.AllowedChildContentTypeIDs;

            foreach (cms.businesslogic.ContentType ct in docType.GetAll())
            {
                ListItem li = new ListItem(ct.Text, ct.Id.ToString());
                AllowedContentTypes.Items.Add(li);
                if (!Page.IsPostBack)
                {
                    foreach (int i in allowedIds)
                    {
                        if (i == ct.Id)
                        {
                            li.Selected = true;
                        }
                    }
                }
            }

            pp = new uicontrols.Pane();
            pp.addProperty("Tilladte indholdstyper", AllowedContentTypes);
            Panel3.Controls.Add(pp);
        }
                public void deletepropertytype_click(object sender, System.EventArgs e)
                {
                    Button s = (Button)sender;
                    int    propertytypeId = int.Parse(s.ID.Replace("propertytype", ""));

                    cms.businesslogic.propertytype.PropertyType.GetPropertyType(propertytypeId).delete();

                    ent.GenericPropertyTypes.Controls.Clear();
                    ent.loadGenericPropertyTypesOnPane();

                    BasePages.BasePage bp = (BasePages.BasePage) this.Page;
                    bp.speechBubble(BasePages.BasePage.speechBubbleIcon.info, ui.Text("speechBubbles", "contentTypePropertyTypeDeleted", null), "");
                    ent.OnPropertyTypeDelete(this, new System.EventArgs());
                }
		protected void Page_Load(object sender, System.EventArgs e)
		{
			prnt = (BasePages.BasePage) this.Page;
			// Setup tab 1
			setupGeneralInfoTab();
			setupTabTab();
			setupGenericPropertyTypesTab();

			AllowedContentTypes = new ListBox();
			AllowedContentTypes.ID = "AllowedContentTypes";
			AllowedContentTypes.SelectionMode = ListSelectionMode.Multiple;
		

			int[] allowedIds = docType.AllowedChildContentTypeIDs;

			foreach (cms.businesslogic.ContentType ct in docType.GetAll()) 
			{
				ListItem li = new ListItem(ct.Text,ct.Id.ToString());
				AllowedContentTypes.Items.Add(li);
				if (!Page.IsPostBack) 
				{foreach (int i in allowedIds) if (i == ct.Id) li.Selected= true;}
			}

			pp = new uicontrols.Pane();
			pp.addProperty("Tilladte indholdstyper",AllowedContentTypes);
			Panel3.Controls.Add(pp);
		}