using System.Windows.Forms; namespace VPScriptEditor { public partial class CommentForm : Form { public string Comment { get { return richTxtComment.Text.Length > 0 ? richTxtComment.Text : null; } } public CommentForm(int pointerNb, string comment) { InitializeComponent(); richTxtComment.Text = comment == null ? "" : comment; this.Text = "Comment for pointer " + (pointerNb + 1); } private void bttnOK_Click(object sender, System.EventArgs e) { Close(); } } }