Textbox grow and cover other objects?

maw230

somewhat competent
Local time
, 18:34
Joined
Dec 9, 2009
Messages
522
I've found some code that will let me have a textbox grow on Mouse Over. The idea being that I want to keep the textbox small unless a user mouses over it, and they can then see all of the textbox contents. I've got code that will change it back to it's normal size after leaving the textbox as well.

Can I make the textbox "draw over" other nearby objects, so that it is in the foreground? Currently, the box grows, but it hidden by other nearby textboxes.

Edit: Well it looks like I just wasn't setting the Height large enough. I set it at .25 thinking it was in inches like it is in the property window, but I guess it's not. Seems to be working for now.

Edit 2: Not working afterall. It looks like it's working sometimes then the next time other objects will show through it. If I take a screenshot it looks fine in the screenshot no matter what it looks like on screen. Basically the check box and text box below the textbox I am making larger can be seen through said textbox.
 
Last edited:
One of the tricks for efficient programming is not inventing new facilities but sticking with what is on offer... or asking if you do not know what is available.

Try

DoCmd.RunCommand acCmdZoomBox

instead of mucking about with control sizes :D
 
Hey, that's pretty neat. I think I'll use that if someone clicks on it, but for just hovering I wanted something a little cleaner.

For now, I'm just going to hide the other controls on mouse over using this:

Code:
Private Sub ActionTaken_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
If Me.ActionTaken.Height <> 1000 Then
Me.ActionTaken.Height = 1000
Me.SentUserGuide.Visible = False
Me.cmb_Analyst.Visible = False
End If

Seems to be doing the job well, but thanks for the suggestion. I'm sure I will use that at some other point! :cool:
 

Users who are viewing this thread

Back
Top Bottom