Results 1 to 2 of 2

Thread: form appearance

  1. #1

    Thread Starter
    New Member
    Join Date
    Oct 2000
    Location
    Posts
    3
    Hi,
    I want my form be visible only when the mouse is pointing on
    it.

    Can anyone tell me how to implement it?

    Thank you in advance!!

    yli
    yli

  2. #2
    Addicted Member
    Join Date
    Sep 1999
    Posts
    229


    This sample only works in MDIForm
    (which you can modify to suit your need on normal form).
    Step 1: Create a MDI form
    Step 2: Create a MDIChild Form
    Step 3: Put the code below in MDI form:

    The concept: Set visible=true everytime the MDIChild form
    is in the ranges of X and Y coor of the mouse.

    -------------

    Private Sub MDIForm_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
    If (X > Form1.Left) And (X < (Form1.Left + Form1.Width)) Then
    If (Y > Form1.Top) And (Y < (Form1.Top + Form1.Height)) Then
    Form1.Visible = True
    Else
    Form1.Visible = False
    End If
    Else
    Form1.Visible = False
    End If
    End Sub

    -------------

    Hope can help

    Regards
    Keiko


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width