+ Reply to Thread
Results 1 to 4 of 4

Transfer percentage into UserForm

  1. #1
    Registered User
    Join Date
    06-22-2007
    Posts
    42

    Transfer percentage into UserForm

    Yet again with this coding! Sorry.

    My spreadsheet has percentages in but doesn't transfer into the UserForm - it transfers as 0.25 instead of 25%.

    Is there a way I can have the UserForm showing 25% rather than the decimal format?

    Please Login or Register  to view this content.
    Last edited by KA_Analyst; 08-01-2007 at 08:22 AM.

  2. #2
    Forum Contributor
    Join Date
    07-05-2007
    Location
    Lexington, MA
    Posts
    302

    Format the string

    "23.3%" = Format(.233, "0.0%")

  3. #3
    Registered User
    Join Date
    06-22-2007
    Posts
    42
    Sorry - being really dumb here, I have not a lot of knowledge of VBA, where do I format it?

  4. #4
    Forum Moderator davesexcel's Avatar
    Join Date
    02-19-2006
    Location
    Regina
    MS-Off Ver
    MS 365
    Posts
    12,895
    Private Sub UserForm_Initialize()
    TextBox1.Value = Format(Range("I1"), "0.0%")

    End Sub
    This populates the textbox when you open the userform

+ 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