Label within a label?
Hi guys. I have an interesting issue. I have labels created dynamically at runtime in my app, and placed in a flow panel. What I need is for some of those labels to have an extra label with a single digit placed in one corner. What I have so far done is created a class which derives from a label AND has a label in it.
However when the Slide class is created, and the SetUpSlide() method called, nothing happens. The label does not appear. Whether I am going about this the wrong way or there is something wrong with my code I'm not sure. Cheers, Jacob.
class Slide : Label
public Label l_IndexLabel;
l_IndexLabel = new Label();
public void SetUpSlide()
l_IndexLabel.Text = this.Tag.ToString();
l_IndexLabel.Size = new System.Drawing.Size(10, 20);
l_IndexLabel.BorderStyle = BorderStyle.FixedSingle;
l_IndexLabel.Location = new System.Drawing.Point(this.Right - 10, this.Top + 20);
PS. Do I need to add it (l_IndexLabel) to a collection? Even if its part of the Slide class?