I don't want cursor pointing/flashing in any of the textbox. How to do that?
Printable View
I don't want cursor pointing/flashing in any of the textbox. How to do that?
is this your looking for
Code:Private Sub Text1_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
Me.Text1.MousePointer = 1
End Sub
Look at the HideCarat API
I dont want have | in the textbox. Look at textbox6 "data tambahan" have this symbol | . Don't want this.How?
Hack, That api should be called with in a timer , correct ?
Code:Option Explicit
Private Declare Function HideCaret Lib "user32" (ByVal hwnd As Long) As Long
Private Sub Timer1_Timer()
HideCaret Me.Text1.hwnd
End Sub
It don't works. Still have | in the textbox.
No, the code i posted works well with my text box.
attached.
Yes, it work.When I create my own, it doesn't work. Did you setting in your textbox?
Put it in the GotFocus event of the textbox.Quote:
Originally Posted by Fazi
Yes, It works now when I put it in the gotfocusQuote:
Originally Posted by Hack
In case you might need it for some future project, there is a corresponding ShowCarat API as well.
Thank you both of you :thumb: :afrog:
But i am afride on the follwing seane.
ok, assume you put that code on TextBox_Got Focus event.
Now you click on the text box, so the caret will not be displayed.
now you click another window i.e. task bar. now again you click your form to get back the focus. Now the caret will be shown on the text box ;)