General discussion

Locked

Attach text (string) with mouse pointer?

By trupti_korde ·
Hi

I want to attach string with the mouse pointer so that whenever i will move the mouse that string also moves with the pointer.

please tell me how to do this...

Trupti.

This conversation is currently closed to new comments.

1 total post (Page 1 of 1)  
Thread display: Collapse - | Expand +

All Comments

Collapse -

Using VB

by Murali Bala In reply to Attach text (string) with ...

This is a simple way to implement...in Visual Baisc..i am sure there are other (better) ways to do it...

1. Drop a label on the form
2. Copy the following code

Private Sub Form_Load()
Label1.Caption = "Hello World"
End Sub

Private Sub Form_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
Label1.Top = Y
Label1.Left = X
End Sub

Hope this helps.

Back to Web Development Forum
1 total post (Page 1 of 1)  

Related Discussions

Related Forums