I have a web form in vb.net and a multiline textbox. I need to add predefined text (selected by the user) and append it to the textbox. However, the user requires that every time the text is appended, the text box automatically scrolls to the end to show the new appended text. I have tried multiple options, including .ScrollToCaret()
and .SelStart()
, but those methods are not available in a Web form. Also, .Append()
method does not do it. This is a Web Application under vb.net in Visual Studio 2022. Any help would be appreciated.
I try this, but it is not supported:
With txtIndicacionesExtras
.Text &= Texto
.SelStart = &HFFFF& 'Len(TextBox.Text) is less efficient than a constant value
.SelText = "Text to append"
.SelText = vbNewLine
txtIndicacionesExtras. = .Text.Length
.ScrollToCaret()
End With
Alejandro Medina de Wit is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.