Пример #1
0
        protected override Control CreateHostedControl()
        {
            TextBox box = new EditableDataGridTextBox();                            // Our hosted control is a TextBox

            box.BorderStyle = BorderStyle.None;                                     // It has no border
            box.Multiline   = this.MultiLine;
            box.ReadOnly    = this.ReadOnly;

            box.AcceptsReturn = false;
            box.TextAlign     = this.Alignment;                                     // Set up aligment.
            if (this._maxTextLength != -1)
            {
                box.MaxLength = _maxTextLength;
            }
            WireTextBoxEvents(box);

            return(box);
        }
        protected override Control CreateHostedControl()
        {
            TextBox box = new EditableDataGridTextBox();                                            // Our hosted control is a TextBox

            box.BorderStyle = BorderStyle.None;                                     // It has no border
            box.Multiline = this.MultiLine;
            box.ReadOnly = this.ReadOnly;

            box.AcceptsReturn = false;
            box.TextAlign = this.Alignment;                                         // Set up aligment.
            if (this._maxTextLength != -1) { box.MaxLength = _maxTextLength; }
            WireTextBoxEvents(box);

            return box;
        }