In order to this u have to do a bit of formatting
white spaces are not so helpful
in order to implement the text in two columns u need to work out how many tabs u need to add between two columns of each row. Because 1st cel of 1st row might be too short and same of 1nd row might b too long. So just adding one tab in between two columns of each row will end up some this kind of formatting
b1 book1
gudbooks bok2
Books braveBooks
dontumindit myStuff
haythatscooliloveit Really
the reason is that 1st column of each row differs in length
to over come this problem, u need to work out whats the maximum length of the text which is going to be added, and for each row u need to work out how many tabs to be addedd
private void Form1_Load(object sender, EventArgs e)
{
string[] arr = { "b1", "book1", "gudbooks", "bok2", "Books", "braveBooks", "dontumindit", "myStuff", "haythatscool,iloveit", "Really" };
int maxlen = 0;
for (int i = 0; i < arr.Length; i++)
{
if (i % 2 == 0)
if (maxlen < arr[i].Length)
maxlen = arr[i].Length;
}
MessageBox.Show(maxlen.ToString());
int minimumTabSpace = 2;
int noOftabs = (maxlen / 8) + minimumTabSpace;
string ToolTipText = "";
for (int i = 0; i < arr.Length; i++)
{
ToolTipText += arr[i];
if (i % 2 != 0)
{
ToolTipText += Environment.NewLine;
}
else
{
for (int j = 0; j < noOftabs - (arr[i].Length / 8); j++)
ToolTipText += "\t";
}
}
toolTip1.SetToolTip(button1, ToolTipText);
}
if u have too many white spaces in the text, then u need to work more to get proper allignment.
Best of Luck.