Hi,
Code below add StatusStrip with one LabelElement to form.
How to get the parent control of LabelElement by code?
Later on in my code, i must call Invoke method on StatusStrip, but i have only access to LabelElement
// Add statusbar
RadStatusStrip status =
new
RadStatusStrip();
Controls.Add(status);
// Add label to statusbar
RadLabelElement label =
new
RadLabelElement();
label.Text =
"test"
;
status.Items.Add(label);
// This is only radelement
RadStatusBarElement RadStatusBarElement = (RadStatusBarElement)label.Parent.Parent;
// Can't convert like that
RadStatusStrip RadStatusStrip = (RadStatusStrip)RadStatusBarElement;