finalrow

  1. B

    FinalRow in VBA not working

    Hello, Can someone tell me what's going wrong? Starting to learn VBA. I hope I can help you guys back in the future :)
  2. M

    New problem - FinalRow based on two criteria?

    Hello and thanks for reading this! (I apologize for length, but want to be thorough so you don't have to try and read my mind. Good question = good answer right?) The code below works the first time through, but the code will be ran multiple times. It's a two step copy and paste based on...
  3. A

    Setting Data Validation causes 1004 error.

    Good afternoon all, I have a macro enabled workbook running in Excel 2016. On one tab I've set up a button that runs a macro that will add a new row to a table and set some values in it. Here's the code. Sub ServiceHealth_Tbl() Dim lo As ListObject Dim FinalRow As Long Dim myValue As...
  4. N

    VBA to delete rows with a formula that equals blank

    I've created a button that incorporates a bunch of functions. Everything is working, but the process started taking an extremely long time after I added the function below. What I'm do with this function is deleting all of the rows that have formulas in them that end up equaling a blank cell...
  5. G

    Need help to convert Excel to Word

    Hi Everyone, Here i am trying to convert data's from excel to word as a letter format but as i debugged and checked, from the highlighted line the code is skipped. Can i know what wrong i have done/what changes i should make???? https://app.box.com/s/ylrujmxp79v84m0ejc50jw7spheo8a1y In above...
  6. K

    finalrow = Cells(Rows.Count, 1).End(xlUp).Row - Final Row showing as 0

    Hi I am trying to create a macro to copy data from one sheet to another The data is not copying across Below is my code, the final row appears to be 0 Appreciate any thoughts Thanks kind Regards ken Sub Macro1() ' ' Macro1 Macro : Extract data to another Sheet ' Dim datasheet As...
  7. rinneii

    ColorIndex and Offset

    I need to use the offset property to get color in another column. This is what I have so far: Option Explicit Dim FinalRow As Integer Dim i As Integer Sub Colorfruit() FinalRow = Cells(Rows.Count, 1).End(xlUp).Row For i = 3 To FinalRow If Cells(i, 1).Value = "Grapefruit" Then With...
  8. D

    macro messing up table

    i have a table with three columns...whenever i use the macro to enter new data in the table, it messes it up and it's no longer dynamic. after the macro, if i manually enter data again, the table does not expand. 'put time stamp Sheets("Time Stamp").Select finalrow = Cells(Rows.Count...
  9. H

    Compile error wrong number of arguments or invald property assignment

    Am getting that compiler error on this very simple code: Sub app() finalrow = Cells(Rows, Count, 1).End(xlUp).Row For x = 1 To finalrow If Cells(x, 1) = 50 Then Cells(x, 1).Interior.ColorIndex = 3 End If Next x End Sub I wrote 10 numbers in column A including a "50" so it could turn red. I...
  10. D

    clenaner code to sort

    hi guys used the recorder for this finalrow = Cells(Rows.Count, "A").End(xlUp).Row ActiveWorkbook.Worksheets("Domestic NI").Sort.SortFields.Clear ActiveWorkbook.Worksheets("Domestic NI").Sort.SortFields.Add Key:=Range( _ "A10:A" & finalrow), SortOn:=xlSortOnValues...
  11. E

    Search code - See any issues?

    found this piece code and its exactly as presented. It works in the provider demo, but not in my new workbook. Error occurs at the bold red print (object define error) Sub search_and_extract_singlecriteria() Dim datasheet As Worksheet Dim reportsheet As Worksheet Dim typename As String Dim...
  12. L

    Select Cell Data Last Entered Into After Auto-Sort

    Hello all! I have the following code that auto-sorts my table based on a value in column F. Once sorted, the cursor goes to the bottom of the table. How would I change this code to force the cursor to "follow" the cell in which data was last entered after the sort? The cell is dynamic because...
  13. P

    Modify Code found on the Web

    Below is the original code that I found which will find the word "Excel" in worksheet named "Source" from Range("A1:A10000") and the return the range address for the word. Sub x() Dim rngX As Range Set rngX = Worksheets("Source").Range("A1:A10000").Find(" Excel", lookat:=xlPart)...
  14. D

    Returning #REF! Error

    Hello, I'm running the below macro that I'm finding data from a table that I've created. The issue that I'm running into is the table that I have created does not have all the information I'm looking for side by side. At the end of the table I've created 5 column's to pull the information I'm...
  15. H

    Exclude certain banches in Col Y when extracting data

    I have the following macro below I want have certain branches (Br1, Br2 & Br3) in Col Y which I want to exclude when extracting the data when the code below was set as If cel3 <> "BR1" Or "BR2" Or "BR3" Then Branches.Add CStr(cel3), CStr(cel3) [ , the code copies the data except BR1...
  16. J

    SUMIFS - with FinalRow criteria

    I have a formula which looks at another worksheet and then completes a calculation if criteria is met. =SUMIF(DataDrop!$C$3:$C$2824,"=PKD000",(DataDrop!$P$3:$P$2824)) Is there a way of incorporating the FinalRow into this formula as when I have tried in numerous ways it results in an error...
  17. T

    error retreving data from access to excel

    not sure why I am getting this error: no value given for one or more required parameters. Here is my code - can anyone point me in the right direction? Sub GetRecords() Dim cnn As ADODB.Connection Dim RST As ADODB.Recordset Dim WSOrig As Worksheet Dim WSTemp As Worksheet Dim sSQL As String...
  18. P

    Offset values not being entered into spreadsheet

    I not sure why the below code is not adding my userform entries to the spreadsheet. I did a CompileVBAProject test and there were no issues. I stepped through the program and no error messages appeared. What this program is suppose to do is it will find the final row with a value in it and add...
  19. P

    How to pass values

    In my workbook I have seven sheets. Sheets four through seven contain values of product information for our four production lines. The below code starts on sheet 4 and loops through each row of column B until it finds the value of the combobox located on the userform named Chattem or...
  20. R

    Odd Error - Once in a While

    Hello, I'm Receivng an error when I open a workbook: Any ideas as to what may be causing it? The workook is an xlsx workbook, so no macros/VBA. Although, a macro is used to create the workbook and there is a sort associated with that macro but that code is in a different workbook. Thank...

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