Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Apply conditional formatting on MouseMove Event

Status
Not open for further replies.

WalkieTalkie

Technical User
Feb 15, 2002
91
NZ
In Access 2003, have a continuous form with three textboxes:
[PaymentDate]
[PaymentType]
[PaymentAmount]

To edit a record, the user clicks on PaymentDate, and a single form pops up showing only the record selected.

I want the PaymentDate texbox to change to FontUnderline = True when the user hovers the mouse over the PaymentDate textbox (ie on the MouseOver event).

With the built-in Conditional Formatting, I can achieve this but only when the textbox receives the focus; not on the MouseOver event. I'm sure it must be possible to write code to achieve this, but its a bit beyond my abilities. Can anyone suggest code that would achieve this?
 
How are ya WalkieTalkie . . .

Biggest problem is [blue]telling which record the mouse hovers over![/blue] This can be done with some math using the y-axis, but its only as good as a screen full of records. If your record listing is long enough to require verticle scrollbars the math is highly compounded. Add to this different screen resolutions and [blue]it all turns into a can of worms![/blue]

In my opinion its better to just stick with the focus event ... espcially for such a simple result. I'm not trying to rain on your parade ... but I think you see the problem.

[blue]Your Thoughts? . . .[/blue]

See Ya! . . . . . .

Be sure to see thread181-473997 [blue]Worthy Reading![/blue] [thumbsup2]
Also faq181-2886 [blue]Worthy Reading![/blue] [thumbsup2]
 
Thanks, Ace.

I had read that elsewhere too, but thought there must be a work around. If the AceMan can't do it, it can't be done! Shame, though. It would be good to have the same effect as a hyperlink - showing the user to click on a label for more info.

Thanks again.
 
Ace Man did not say he could not do it, he said it was problematic. If you can limited the amount of records displayed so that the user does not get a scroll bar this can be done easily. As Ace Man said, once the scroll comes in to affect it gets more difficult.
Here is a demo, it works fine until you scroll records. So you could set up a form like a web page were you return x amount of records at a time.


If there is a way to return the first records displayed in a continous form (I do not know how) then you could fix the scroll issue.

You could get a solution using the API. If you go to lebans.com he has several classes that return the current record moused over. You can see a demo here:
 
Thanks for sharing that, MaJp. Its a bt clunky but I can see where its going. Cheers
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top