cellsrows.count

  1. M

    How can apply "LastRow" in the formula

    Hello, I am trying to add in the formula select "LastRow" but can't get it work Formula below works perfect look value in the C9 Sub FillArrayFormula() Dim LastRow As Long LastRow = Cells(Rows.Count, "DJ").End(xlUp).Row + 1 Range("DJ" & LastRow).FormulaArray =...
  2. B

    Sum VBA

    Using the following code to Sum columns 12 through 18, however the totals are incorrect, not sure what I am doing wrong. Code I am using For i = 12 To 18 lr = Cells(Rows.Count, i).End(xlUp).Row If lr > 12 Then Cells(lr + 1, i) =...
  3. L

    Userform to pause Macro then resume when form is closed

    I have a macro that I am trying to create and the first portion works perfectly but there are times where the user will need to make manual adjustments before the final step of the macro is completed. I tried adding a Modeless userform to accomplish this but now it starts at the userform and...
  4. R

    If(isnumber(search) vba

    HI Guys i have the following table I L S Mr John Smith Mr Jack Paul and Mrs Jack Paul my vba codes are as follows:- Sub x() Dim TR As Long TR = Cells(Rows.Count...
  5. S

    AutoFill Destination Range Error: Expected List Separator

    Greetings, I am having trouble with the last line. I would like to use a variable "a" to define the last row in the Destination range but am receiving an error. a = Cells(Rows.Count, "A").End(xlUp).Row Range("J2:BC2").Select Selection.AutoFill Destination:=Range("Cells(2...
  6. S

    Vba to find multiple specific values and copy and paste them to different locations

    Hello. I am trying to reorganise some data. I have a list of numbers in column A. I want my code to look in column A for all the rows with "350" and copy and paste those rows to U4. I want it to do this for all the different numbers. There is over 100 of them. This is what i have so far but it...
  7. T

    Excel VBA to hide columns

    I am scratching my head trying to work out why this simple bit of vba doesn't work. I have a simple loop to find the first column number in a range that isn't empty. Then I hide all columns in the range apart from the last one that wasn't empty. What I can't understand is that this works on...
  8. A

    Finding next blank cell error

    Everything in my code works perfectly except the line marked below. Can someone help me figure out how to get it to find the next blank row and then paste. If I take the line of code out, it works but it replaces the previously saved data. Private Sub CommandButton1_Click() With...
  9. B

    VBA Else IF statement

    Hi guys, the following macro seems to run a little slow, is there anyway of making the code more efficient / run faster ? Sub Adjust() ' ' Adjust Macro ' ' Keyboard Shortcut: Ctrl+a ' Dim lr1 As Long Dim lr2 As Long Application.ScreenUpdating = False Range("A2:AQ" &...
  10. D

    Matching Visible column / row contents from 2x different Tables

    Hello Mr. Excel Forum members, I need you help and advice. The code below works fine but I wanted to get away from hard coding the column / row numbers and use the Table header names instead. Any help would be greatly appreciated. -Don If rNumber_of_Rows = Number_of_Rows Then...

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top