+ Reply to Thread
Results 1 to 5 of 5

Round to nearest 1000 VBA

Hybrid View

WAW Round to nearest 1000 VBA 11-16-2010, 12:48 PM
TMS Re: Round to nearest 1000 VBA 11-16-2010, 01:04 PM
shg Re: Round to nearest 1000 VBA 11-16-2010, 06:15 PM
WAW Re: Round to nearest 1000 VBA 11-24-2010, 06:55 AM
TMS Re: Round to nearest 1000 VBA 11-24-2010, 07:17 AM
  1. #1
    Registered User
    Join Date
    01-05-2010
    Location
    liverpool, england
    MS-Off Ver
    Excel 2007
    Posts
    44

    Round to nearest 1000 VBA

    Hi Guys

    Anyone know how to round to the nearest 1000 using VBA.

    Thanks
    Last edited by WAW; 11-24-2010 at 06:55 AM.

  2. #2
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    48,465

    Re: Round to nearest 1000 VBA

    Range("H1") = Application.WorksheetFunction.Round(Range("I1"), -3)


    Regards
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


  3. #3
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689

    Re: Round to nearest 1000 VBA

    Or
    Range("H1") = Round(Range("I1").Value/1000, 0) * 1000
    Entia non sunt multiplicanda sine necessitate

  4. #4
    Registered User
    Join Date
    01-05-2010
    Location
    liverpool, england
    MS-Off Ver
    Excel 2007
    Posts
    44

    Re: Round to nearest 1000 VBA

    Excelent thanks

  5. #5
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    48,465

    Re: Round to nearest 1000 VBA

    You're welcome. Thanks for the feedback.

+ 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