+ Reply to Thread
Results 1 to 3 of 3

Userform-Change textbox color and font based on input in other tex

  1. #1
    Neal
    Guest

    Userform-Change textbox color and font based on input in other tex

    Dear Excel Programming People,

    I have a userform with multiple textboxes. I have textbox A where the user
    inputs a number. If the number is higher than 50, I want textbox B to show
    that number in red and bold, but if the number is less than 50, I want
    textbox B to show the number in black and normal font. I have it where it
    becomes red (ComputeBox.ForeColor = 255), but cannot get it to be bolded.
    What is the code for that? Thanks in advance.

    Neal

  2. #2
    Ron de Bruin
    Guest

    Re: Userform-Change textbox color and font based on input in other tex

    Hi Neal

    Me.TextBox1.Font.Bold = True


    --
    Regards Ron de Bruin
    http://www.rondebruin.nl


    "Neal" <[email protected]> wrote in message news:[email protected]...
    > Dear Excel Programming People,
    >
    > I have a userform with multiple textboxes. I have textbox A where the user
    > inputs a number. If the number is higher than 50, I want textbox B to show
    > that number in red and bold, but if the number is less than 50, I want
    > textbox B to show the number in black and normal font. I have it where it
    > becomes red (ComputeBox.ForeColor = 255), but cannot get it to be bolded.
    > What is the code for that? Thanks in advance.
    >
    > Neal




  3. #3
    Neal
    Guest

    Re: Userform-Change textbox color and font based on input in other

    Ron,

    Thanks. It works perfectly.

    Neal

    "Ron de Bruin" wrote:

    > Hi Neal
    >
    > Me.TextBox1.Font.Bold = True
    >
    >
    > --
    > Regards Ron de Bruin
    > http://www.rondebruin.nl
    >
    >
    > "Neal" <[email protected]> wrote in message news:[email protected]...
    > > Dear Excel Programming People,
    > >
    > > I have a userform with multiple textboxes. I have textbox A where the user
    > > inputs a number. If the number is higher than 50, I want textbox B to show
    > > that number in red and bold, but if the number is less than 50, I want
    > > textbox B to show the number in black and normal font. I have it where it
    > > becomes red (ComputeBox.ForeColor = 255), but cannot get it to be bolded.
    > > What is the code for that? Thanks in advance.
    > >
    > > Neal

    >
    >
    >


+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1