+ Reply to Thread
Results 1 to 4 of 4

Divide Then Round VBA

Hybrid View

  1. #1
    Registered User
    Join Date
    01-08-2015
    Location
    Phoenix, Arizona
    MS-Off Ver
    2013
    Posts
    11

    Divide Then Round VBA

    I'm looking to select a range of sheets then divide numbers in column "E" by "0.93" and round to the nearest whole dollar.

  2. #2
    Forum Expert
    Join Date
    08-12-2012
    Location
    Sydney, Australia
    MS-Off Ver
    Excel 2010
    Posts
    5,636

    Re: Divide Then Round VBA

    select a range of sheets ...then divide numbers in column E..is your range column E?

    is it each number in column E or all the numbers combined?
    how many rows?
    where do you output?
    If you are satisfied with the solution(s) provided, please mark your thread as Solved.
    Select Thread Tools-> Mark thread as Solved. To undo, select Thread Tools-> Mark thread as Unsolved.

  3. #3
    Forum Expert
    Join Date
    10-06-2008
    Location
    Canada
    MS-Off Ver
    2007 / 2013
    Posts
    5,543

    Re: Divide Then Round VBA

    According to the information supplied, this should work.
    Sub Maybe()
        Dim i As Long, j As Long
        For i = 2 To ActiveWorkbook.Sheets.Count
            With Sheets(i)
                For j = 2 To .Cells(.Rows.Count, 5).End(xlUp).Row
                    .Cells(j, 5).Value = WorksheetFunction.Round((.Cells(j, 5).Value / 0.93), 0)
                Next j
            End With
        Next i
    End Sub

  4. #4
    Forum Expert
    Join Date
    10-06-2008
    Location
    Canada
    MS-Off Ver
    2007 / 2013
    Posts
    5,543

    Re: Divide Then Round VBA

    Still wondering if it worked or not

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Replies: 2
    Last Post: 12-06-2014, 01:58 PM
  2. [SOLVED] How to round to nearest .01 and round down if thousands place is .005
    By dredre609 in forum Excel General
    Replies: 5
    Last Post: 09-29-2014, 11:47 AM
  3. [SOLVED] Divide a number by 32 then get the value to round to the nearest .5
    By KazzICC in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 07-01-2014, 01:01 AM
  4. [SOLVED] Conditional Round up or Round up Function
    By cdmterence in forum Excel Programming / VBA / Macros
    Replies: 17
    Last Post: 09-18-2013, 06:03 PM
  5. [SOLVED] Divide and NOT Round in one formula
    By 1crazycajun in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 08-26-2012, 10:53 PM
  6. Replies: 0
    Last Post: 06-27-2006, 06:10 PM
  7. [SOLVED] How do I ROUND() round off decimals of a column dataset?
    By Højrup in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 01-12-2005, 07:06 AM

Tags for this Thread

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