1

This code works on textbox but not on multiline textbox how can I change this for my multiline textbox?

<DllImport("user32.dll", CharSet:=CharSet.Auto)> _
Private Shared Function SendMessage(ByVal hWnd As IntPtr, ByVal msg As Integer, ByVal wParam As Integer, <MarshalAs(UnmanagedType.LPWStr)> ByVal lParam As String) As Int32
End Function

SendMessage(Me.textbox1.Handle, &H1501, 0, "Enter User name here") this code come from this How to set TextBox hint label in VB .NET?

1 Answers1

0

You cannot do this. See

You cannot set a cue banner on a multiline edit control or on a rich edit control.

https://learn.microsoft.com/en-us/windows/win32/controls/em-setcuebanner

user14797724
  • 109
  • 1
  • 3