Unplanned
Last Updated: 29 Jun 2022 09:05 by Dinko
When a layout is loaded the last selected group will be ignored. After loading the layout the last added group will be selected which is not expected.
Completed
Last Updated: 29 Apr 2022 13:19 by ADMIN
Release R2 2022

It is possible to add one control, but when when you try to add other controls to the layout, just sits where you place it rather than split in to sections. 

Expected:

Actual:

 

Unplanned
Last Updated: 28 Apr 2021 08:01 by ADMIN
Created by: James William
Comments: 0
Category: LayoutControl
Type: Bug Report
0
I am using a RadLayoutControl in one of my applications and suddenly it started to throw IndexOutOfRangeException while editing the layout both in the designer and at runtime.

I just found out that after removing the padding on the control it started working fine again. I had recently added padding to add some space between the layout and the docked command bar.

So it looks like the RadLayoutControl dos not like having padding. The exception was being thrown in Telerik.WinControls.UI.LayoutTree.GetDropTargetNode(DraggableLayoutControlItem dropTargetElement, Point mousePosition, Type dragContext)

For the time being, I will add an empty space at the top of the layout instead of using padding.

Hope it can help you resolve this bug.
Completed
Last Updated: 23 Jan 2020 11:57 by ADMIN
Release R1 2020 SP1 (LIB 2020_1_127)

I can not add any type of control to the layoutControlGroupItem.  I have a screen recording of me trying to follow the procedure shown but it is 60M so I can't attach it.  I shared the file on my OneDrive if you would like to access it that way.

 

https://ryancentral-my.sharepoint.com/:v:/p/jeff_burke/EV_FvUkDAUtLlWgYelxCxeoB52z_0522xoFurCSQNa-dbw?e=s2WOe5

 

 

Completed
Last Updated: 15 Aug 2019 14:26 by ADMIN
Release R3 2019 (LIB 2019.2.819)

To reproduce:

private void RadButton5_Click(object sender, EventArgs e)
{
    RadButton labelControl = new RadButton();
    labelControl.Size = new Size(200, 30);
    labelControl.Text = "Test";

    layoutControlItem1.AssociatedControl = labelControl;
}

Workaround: 
private void RadButton5_Click(object sender, EventArgs e)
{
    RadButton labelControl = new RadButton();
    labelControl.Size = new Size(200, 30);
    labelControl.Text = "Test";

    ((RadLayoutControlControlCollection)this.radLayoutControl1.Controls).RemoveInternal(layoutControlItem1.AssociatedControl);
    ((RadLayoutControlControlCollection)this.radLayoutControl1.Controls).AddInternal(labelControl);
    layoutControlItem1.AssociatedControl = labelControl;

    layoutControlItem1.UpdateControlBounds();
   
}

 

Completed
Last Updated: 05 Feb 2019 15:48 by ADMIN
Hide Item option in the context menu should not be present for those items. We should also consider a cancellable ItemHiding event. The custom control below handles this scenario:

public class CustomRadLayoutControl : RadLayoutControl
{
    public override string ThemeClassName
    {
        get
        {
            return typeof(RadLayoutControl).FullName;
        }
    }

    protected override void InitializeDropDownMenu()
    {
        FieldInfo hideMenuItemFi = typeof(RadLayoutControl).GetField("hideMenuItem", BindingFlags.Instance | BindingFlags.NonPublic);
        RadMenuItem hideMenuItem = hideMenuItemFi.GetValue(this) as RadMenuItem;

        if (hideMenuItem == null)
        {
            hideMenuItemFi.SetValue(this, new RadMenuItem(LayoutControlLocalizationProvider.CurrentProvider.GetLocalizedString(LayoutControlStringId.ContextMenuCustomize)));
            hideMenuItem = hideMenuItemFi.GetValue(this) as RadMenuItem;
        }

        hideMenuItem.Click += customizeItem_Click;

        RadDropDownMenu menu = typeof(RadLayoutControl).GetField("dropDownMenu", BindingFlags.Instance | BindingFlags.NonPublic).GetValue(this) as RadDropDownMenu;
        menu.Items.Add(hideMenuItem);
    }

    private void customizeItem_Click(object sender, EventArgs e)
    {
        if (this.AllowCustomize)
        {
            this.ShowCustomizeMenuDialog();
        }
    }

    private void ShowCustomizeMenuDialog()
    {
        if (this.CustomizeDialog.Visible)
        {
            return;
        }

        this.ShowCustomDragOverlay();
        this.CustomizeDialog.Owner = this.FindForm();
        ThemeResolutionService.ApplyThemeToControlTree(this.CustomizeDialog, this.ThemeName);

        if (this.CustomizeDialog.Location == Point.Empty)
        {
            this.CustomizeDialog.Location = GetInitialCustomizeDialogLocation();
        }

        this.CustomizeDialog.Show();
        this.CustomizeDialog.RightToLeft = this.RightToLeft;
    }

    private void ShowCustomDragOverlay()
    {
        FieldInfo dragOverlayFi = typeof(RadLayoutControl).GetField("dragOverlay", BindingFlags.Instance | BindingFlags.NonPublic);
        LayoutControlDraggableOverlay dragOverlay = dragOverlayFi.GetValue(this) as LayoutControlDraggableOverlay;

        if (dragOverlay == null)
        {
            dragOverlayFi.SetValue(this, new CustomLayoutControlDraggableOverlay(this));
            dragOverlay = dragOverlayFi.GetValue(this) as LayoutControlDraggableOverlay;
        }

        dragOverlay.ThemeName = this.ThemeName;
        dragOverlay.UpdatePreview();

        dragOverlay.Dock = DockStyle.Fill;
        ((RadLayoutControlControlCollection)this.Controls).AddInternal(dragOverlay);
        dragOverlay.Visible = true;
        dragOverlay.BringToFront();
        this.PerformLayout();
        this.Refresh();
    }

}

public class CustomLayoutControlDraggableOverlay : LayoutControlDraggableOverlay
{
    private RadMenuItem hideMenuItem;


    public CustomLayoutControlDraggableOverlay(RadLayoutControl owner) 
        : base(owner)
    {
        RadDropDownMenu contextMenu = typeof(LayoutControlDraggableOverlay).GetField("contextMenu", BindingFlags.Instance | BindingFlags.NonPublic).GetValue(this) as RadDropDownMenu;
        contextMenu.Items.Clear();

        this.hideMenuItem = new RadMenuItem(LayoutControlLocalizationProvider.CurrentProvider.GetLocalizedString(LayoutControlStringId.ContextMenuHideItem));
        this.hideMenuItem.Text = LayoutControlLocalizationProvider.CurrentProvider.GetLocalizedString(LayoutControlStringId.ContextMenuHideItem);
        this.hideMenuItem.Click += hideMenuItem_Click;
        contextMenu.Items.Add(hideMenuItem);
        contextMenu.DropDownOpening += ContextMenu_DropDownOpening;
    }

    private void ContextMenu_DropDownOpening(object sender, CancelEventArgs e)
    {
        if (this.SelectedItems.Count == 1 && this.SelectedItems[0].Name == "layoutControlItem4")
        {
            e.Cancel = true;
        }
    }

    private void hideMenuItem_Click(object sender, EventArgs e)
    {
        foreach (DraggableLayoutControlItem item in this.SelectedItems)
        {
            if (item.Name == "layoutControlItem4")
            {
                continue;
            }

            ((CustomRadLayoutControl)this.Owner).HideItem(item.AssociatedItem);
        }

        this.UpdatePreview();
    }
}
Completed
Last Updated: 09 Oct 2018 13:10 by Dimitar
Workaround: handle the RadPropertyChanging and RadPropertyChanged

public partial class RadForm1 : Telerik.WinControls.UI.RadForm
{
    public RadForm1()
    {
        InitializeComponent();
        
        this.layoutControlGroupItem1.RadPropertyChanging += LayoutControlGroupItem1_RadPropertyChanging;
        this.layoutControlGroupItem1.RadPropertyChanged += LayoutControlGroupItem1_RadPropertyChanged;
    }

    private void LayoutControlGroupItem1_RadPropertyChanged(object sender, RadPropertyChangedEventArgs e)
    {
        if (e.Property == LayoutControlGroupItem.IsExpandedProperty)
        {
            Console.WriteLine("IsExpanded Changed");
            Console.WriteLine("Old Value: " + e.OldValue);
            Console.WriteLine("New Value: " + e.NewValue);
        }
    }
}
Unplanned
Last Updated: 12 Jul 2018 13:07 by ADMIN
ADMIN
Created by: Hristo
Comments: 2
Category: LayoutControl
Type: Bug Report
6

			
Completed
Last Updated: 12 Jun 2018 12:38 by Dimitar
Workaround: set a White back color to the control in the designer or use the attached custom theme
Completed
Last Updated: 15 Aug 2017 11:03 by ADMIN
To reproduce:
- Start the attached project. 
- Collapse and then expand the group.
- The label should remain hidden.

Workaround:
bool labelVisiable = false;
private void TxtIdNro_VisibleChanged(object sender, EventArgs e)
{
    if (txtIdNro.Visible && !labelVisiable)
    {
        txtIdNro.Visible = false;
    }
}
Completed
Last Updated: 15 Aug 2017 10:54 by ADMIN
Please run the attached sample project and follow the steps in the document locate din the zipped folder.

Workaround:
this.radLayoutControl1.VerticalScrollbar.ValueChanged += VerticalScrollbar_ValueChanged;

private void VerticalScrollbar_ValueChanged(object sender, EventArgs e)
        {
            this.Width += 1;
            this.Width -= 1;
        } 
Unplanned
Last Updated: 15 Aug 2017 10:02 by ADMIN
ADMIN
Created by: Stefan
Comments: 2
Category: LayoutControl
Type: Feature Request
10

			
Unplanned
Last Updated: 15 Aug 2017 10:02 by ADMIN
Completed
Last Updated: 15 Aug 2017 08:46 by ADMIN
To reproduce:
- Add layout control to a standard Form.
- Make the form smaller so a scrollbar appears in the layout control.
- There is an exception when you are scrolling.

Workaround:
Use RadForm instaed.
Completed
Last Updated: 18 May 2017 07:38 by ADMIN
Completed
Last Updated: 25 Jan 2017 08:34 by ADMIN
To reproduce:
- Open the attached project. 
- Select the second tab and then the inner tabs.
- The layout is not updated.

Workaround:
private void TabStrip_ItemSelected(object sender, RadPageViewItemSelectedEventArgs e)
{
    LayoutControlTabStripElement el = sender as LayoutControlTabStripElement;
    foreach (LayoutControlTabStripItem  item in el.Items)
    {
        var groupItem = item.LayoutGroupItem;
        groupItem.Visibility = Telerik.WinControls.ElementVisibility.Visible;
        groupItem.InvalidateMeasure(true);
        groupItem.InvalidateArrange(true);
        groupItem.UpdateLayout();
        groupItem.Visibility = Telerik.WinControls.ElementVisibility.Collapsed;
    }

    foreach (LayoutControlTabStripItem item in el.Items)
    {
        if (item == e.SelectedItem)
        {
            var groupItem = item.LayoutGroupItem;
            groupItem.Visibility = Telerik.WinControls.ElementVisibility.Visible;
            break;
        }
    }
}

// access event
layoutControlTabbedGroup4.TabStrip.ItemSelected += TabStrip_ItemSelected;
Completed
Last Updated: 28 Dec 2016 09:31 by ADMIN
Workaround: access the tabbed group and remove the group item manually
this.layoutControlTabbedGroup1.ItemGroups.Remove(this.layoutControlGroupItem1);
this.radLayoutControl1.HiddenItems.Add(this.layoutControlGroupItem1);
Completed
Last Updated: 18 Nov 2016 13:34 by ADMIN
The attached video shows how this can be reproduced. 

Workaround: 
private void RadLayoutControl1_MouseWheel(object sender, MouseEventArgs e)
{
    HandledMouseEventArgs ee = (HandledMouseEventArgs)e;
    ee.Handled = true;
}
Unplanned
Last Updated: 26 Aug 2016 09:05 by ADMIN
Currently you cannot add any controls to a panel which is already inside RadLayoutControl. 
1 2