Results 1 to 2 of 2
  1. #1
    Join Date
    Oct 2005
    Posts
    7

    Question Unanswered: Need help with mouseover and condition display on forms

    My form is named form1. It's source is table1. Table1 has three fields that I'm trying to get fancy with. Well, fancy for me, that is. The fields are Notes, Warnings and Screenshot. I want to display "Notes", "Warnings" and "See Screenshot" on the form only if these fields are not blank. If these fields in table1 are blank you shouldn't see the text on the form.

    If you see Notes or Warnings on the form and you mouse over them I want you to see the contents of the respective field. I want to show it to you in a little screen tip box. If you see "See screenshot", you click it and another form will open. The name of the associated form is in the Screenshot field.

    I don't know how to display things conditionally and I've never done anything with mouse overs. Can somebody give me a clue, please?

    Thank you in advance for your assistance,
    DJ (VB Newbie)

  2. #2
    Join Date
    Nov 2003
    Posts
    1,487
    When you scroll through your records, the fields Note, Warnings, and Screenshot is going to obviously change depending whether or not thise particular fields actually contain data and for this reason we will need to place conditional code into the Form's OnCurrent Event to see whether of not the is in fact data available. To do this we could use code like this within the Form's On Current event:

    Code:
    Me.myNotesFieldName.Visible = Not IsNull(Me.myNotesFieldName) 
    Me.MyWarningsFieldName.Visible = Not IsNull(Me.MyWarningsFieldName)	
    Me.myScreenShotsFieldName.Visible = Not IsNull(Me.myScreenShotsFieldName)
    Now in the MouseMove event For the Notes Field You might Have:
    Code:
    If Me.myNotesFieldName.Visible = True Then 
       Me.myNotesFieldName.ControlTipText = Me.myNotesFieldName
    End If
    In The MouseMove Event for the Warnings field you might have:
    Code:
    If Me.MyWarningsFieldName.Visible = True Then 
       Me.MyWarningsFieldName.ControlTipText = Me.MyWarningsFieldName
    End If
    In The OnClick Event for the ScreenShots field you might have:
    Code:
    If Me.myScreenShotsFieldName.Visible = True Then 
       DoCmd.OpenForm Me.myScreenShotsFieldName
    End If
    Simple as that...

    .
    Environment:
    Self Taught In ALL Environments.....And It Shows!


Posting Permissions

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