+ Reply to Thread
Results 1 to 3 of 3

Possible to have number formatting in TextBox?

  1. #1
    Registered User
    Join Date
    05-12-2009
    Location
    Udevalla, Sweden
    MS-Off Ver
    Excel 2007
    Posts
    85

    Possible to have number formatting in TextBox?

    Hi guys.

    I have just created a UserForm with some textboxes in it.

    In the UserForm_Activate I have written some code that fills in the textboxes
    with data from my sheet.

    Like so.

    Please Login or Register  to view this content.
    What I was wondering is if it is possible for the textbox to show the value with
    some number formatting. Particularly I want no decimals and I want to use 1000 separator.

    Anyone have any ideas?
    Last edited by Carlsbergen; 04-27-2010 at 08:50 AM.

  2. #2
    Registered User
    Join Date
    12-10-2009
    Location
    London
    MS-Off Ver
    Excel 2003
    Posts
    34

    Re: Possible to have number formatting in TextBox?

    TextBox2 = Format(ActiveCell.Offset(0, 23).Value, "#,###")

  3. #3
    Registered User
    Join Date
    05-12-2009
    Location
    Udevalla, Sweden
    MS-Off Ver
    Excel 2007
    Posts
    85

    Re: Possible to have number formatting in TextBox?

    Quote Originally Posted by phil_b View Post
    TextBox2 = Format(ActiveCell.Offset(0, 23).Value, "#,###")
    Sweet! Works great!
    Thanks alot!

+ 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