public static void AddMessage(ApiMessage message)
 {
     MainForm.Invoke((MethodInvoker) delegate()
     {
         message.SetPosition(currentMessageCount);
         messageList.Add(message);
         message.Show();
     });
     currentMessageCount++;
 }
 public static void AddMessage(string message)
 {
     MainForm.Invoke((MethodInvoker) delegate()
     {
         ApiMessage tempMessage = new ApiMessage(message);
         tempMessage.SetPosition(currentMessageCount);
         messageList.Add(tempMessage);
         tempMessage.Show();
     });
     currentMessageCount++;
 }