Advertisement
Help Keep Boards Alive. Support us by going ad free today. See here: https://subscriptions.boards.ie/.
If we do not hit our goal we will be forced to close the site.

Current status: https://keepboardsalive.com/

Annual subs are best for most impact. If you are still undecided on going Ad Free - you can also donate using the Paypal Donate option. All contribution helps. Thank you.
https://www.boards.ie/group/1878-subscribers-forum

Private Group for paid up members of Boards.ie. Join the club.

VBA refreshing a control

  • 04-03-2004 02:01PM
    #1
    Moderators, Society & Culture Moderators Posts: 2,687 Mod ✭✭✭✭


    Is it possible to refresh a control in VBA without refreshing the whole form???

    for instance, each time a checkbox is checked, the text in a certain textbox turns green, and when its unchecked, it turns red?

    I know how to do this in the checkboxes click event, but im trying to do it through conditional formatting for the textbox. it works, but you have to change records and come back to see the change, ie it doesnt happen immediately.


Comments

  • Closed Accounts Posts: 333 ✭✭McGintyMcGoo


    In VBA, is it not just "Me.controlname.requery".
    or
    Forms!formnamegoeshere.controlname.requery :confused:


  • Closed Accounts Posts: 8,259 ✭✭✭RicardoSmith


    I'm curious why you'd want to do conditional formatting for the textbox.


  • Moderators, Society & Culture Moderators Posts: 2,687 Mod ✭✭✭✭Morpheus


    My boss didnt want any code in the checkboxes on click event....

    in the end we had to put it there... hes weird but hes the boss :rolleyes:

    In any event it works fine now, see i used conditional formatting in some combo boxes earlier, but they worked ok, i guess its down to the form the combo boxes were on and the form the text box was on and the controls themselves having different types of behaviour!!


  • Closed Accounts Posts: 8,259 ✭✭✭RicardoSmith


    Originally posted by Morphéus
    My boss didnt want any code in the checkboxes on click event....

    in the end we had to put it there... hes weird but hes the boss :rolleyes:

    In any event it works fine now, see i used conditional formatting in some combo boxes earlier, but they worked ok, i guess its down to the form the combo boxes were on and the form the text box was on and the controls themselves having different types of behaviour!!

    I just don't understand why you'd want it.


Advertisement