2

Basically, I want to have a chat like interface - one line with name and time, the next few lines with a message.

In HTML / ASP.Net (or any other web language), this is obviously easy - build a component and just have multiple copies for each chat object.

I have been trying on winforms, and the closest I have come is a TreeView list, but it does not look at all pretty!

I was just wondering if anyone can point me in the right direction of what I need to do to achieve a nice formatted text box in the style of chat applications?

Wil
  • 10,234
  • 12
  • 54
  • 81
  • How about webbrowser control? see http://stackoverflow.com/questions/214124/winforms-html-editor for example – Alex Feb 16 '12 at 12:52

3 Answers3

2

I don't think it's any easier in ASP.Net than it is in Winforms. Try the RichTextBox control - you can control the entire layout (for the most part).

Josh M.
  • 26,437
  • 24
  • 119
  • 200
1

You should use some kind of list view. At least it's the way it's done in WPF. Should be possible in Forms, too.

Zebi
  • 8,682
  • 1
  • 36
  • 42
  • Customizing ListViews in Winforms is not even close to as good as it is in WPF - you will get frustrated quickly! – Josh M. Mar 21 '11 at 22:48
0

You could use ListView and edit the template. At least it's how I've done it in the past.

http://msdn.microsoft.com/en-us/library/system.web.ui.webcontrols.listview.layouttemplate.aspx

Gubi
  • 415
  • 2
  • 10
  • 20