Announcement

Collapse
No announcement yet.

Unconfigured Ad Widget

Collapse

Find And Replace Last Cell With Formula

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Find And Replace Last Cell With Formula

    I would like to create a find and replace macro that looks for the last cell with data in Column C and automatically divides that value by a number. I know how to create a find and replace macro that searches for values, but how to I search for the last cell with data in a specific column? Thanks.

  • #2
    Re: Find And Replace Last Cell With Formula

    Hi

    Perhaps:

    Code:
    Dim myCell As Range
    set myCell = columns(3).find("*",lookin:=xlvalues,searchdirection:=xlprevious)
    If Not myCell Is nothing Then
       myCell.Value = myCell.Value / 2
    End if
    Replace the '2' with whatever number you want to divide the value in the cell by.

    Hope this helps!

    Richard

    Comment


    • #3
      Re: Find And Replace Last Cell With Formula

      Thanks!

      Comment

      Trending

      Collapse

      There are no results that meet this criteria.

      Working...
      X