I browsed the first few pages of searching for "row delete macro" and couldn't find anything that suited my needs very much, so here goes:
What I need to do is automatically delete rows where the entries in column B (date) and column E (string) are the same. It is a very large group of data, so filtering is not exacly an option here.
Here is the twist on it...
I have a column F that contains either "Accepted-Active" or "Accepted-Closed". If I delete a bunch of rows that contain the same column B and E entries, I want to save the row that contains "Accepted-Closed", otherwise I don't particularly care which of the rows is saved.
I have a 20000-row sheet generated by a daily report and I only want to work with about a quarter of this data; any rows that contain "PH4" in the M column. What's the best way to automatically single out this data to work with?
My initial solution was to create a seperate sheet to pull off all the columns with PH4 in the M cell, eg cell A8 would be:
Then I could run lookups off that sheet. However, this feels like a sloppy solution to me, and Excel throws up an error when saving, unable to save external link values with available resources. Is there a better way of going about this?
What I need is a macro to delete a row or rows for a specific range of cells (eg. E20 to E58) when the cells in that range column E is = blank. The cells in column E is formated with a currency sign $. Deleting the row should shift up all rows below. I need to run this macro manually. Excel 2002 SP3.
I want to create a macro the will delete all the rows in a sheet if 1 of 2 conditions are met. The first condition is if a cell is blank or if a cell contains the word "negative"
I have a excel file in which , there is probably a macro which runs when i open the file. The macro checks for a particular file on the D: drive.
I want to delete this macro. The problem is i cannot delete this macro, as it is not appearing in the Macros List.
Also i know i can disable this macro, by pressing the shift key whenever the file is opened.
But i want to delete this macro permanently from this file. I have tried various options like pression Alt-F11 & to locate the macro in module etc & also tried to locate it in the Workbook open event handler. But I cant see the macro.
However, this runs extremely slow. I had to stop it after about 10 min, as it only got to about row 1000 of 20,000.
Sub Delete_Dupes() Dim rw1 As Long: rw1 = 1 Dim rwx As Long: rwx = rw1 Dim stepx As Integer Dim co1 As Integer: co1 = 1 Dim co2 As Integer: co2 = 2 Dim bool1 As Boolean Dim bool2 As Boolean Dim bool As Boolean Dim count As Integer count = 0 Do Until Cells(rwx, co1) = "" stepx = 1 If rwx > rw1 Then On Error GoTo NewCrit bool1 = IsError(Application.WorksheetFunction.Match(Cells(rwx, co1), Range(Cells(rw1, co1), Cells(rwx - 1, co1)), 0)) bool2 = IsError(Application.WorksheetFunction.Match(Cells(rwx, co2), Range(Cells(rw1, co2), Cells(rwx - 1, co2)), 0)).................
I need the tabs of a project action log to auto-populate and auto-delete in a master log. (So when something is added or deleted in a tab it is added or deleted on the master) I use excel a little bit for work and personal finance purposes but I have zero experience with macros or VBA.
Within a data validation selection, are you able to do both Auto Complete and Auto Delete? I have this posted at another forum [url]but have not been able to find a solution (a copy of the file, test. zip is there as well). I am not sure it is possible, or, at least I have been unable to get it working. I can do each, but not both.
I can get it to work with 1 email and 1 condition but not 2.
Sub auto_open() ThisWorkbook.Worksheets("Sheet1").OnEntry = "DidCellsChange" End Sub
Sub DidCellsChange() Dim KeyCells As String KeyCells = "A1:A99" If Not Application.Intersect(ActiveCell, Range(KeyCells)) _ Is Nothing Then KeyCellsChanged End Sub ................................
I know very little about macros (basically just concepts). I found this macro suggested in another thread (posted By VoG II…Thanks)
Sub test() Dim Lastrow As Long Lastrow = Range("A5").Value + 4 Range("B5").AutoFill Destination:=Range("B5:B" & Lastrow), Type:=xlFillSeries End Sub
When this macro is run the first time it will fill in the numbers 2 through 15 (as I had hoped). Given 15 is the variable and 1 is the start of the range...
I have a single registration sheet that lists names, contact information, and the class someone is in on a single sheet.
(Name, Number, Email, Class 1, Class 2)
I am hoping to automatically populate other sheets in my work book based on classes... essentially making automatically populated rosters. For example, everyone who has Math listed in either Class 1 or Class 2 would have their entire row (with contact information, etc) copied to the "Math" sheet.
I am newer here and I want a macro in mentioned title. I have a number in column a2 and in column b2 quantity if in column a2 number is 2101400 and in column b2 i write quantity 50 so said number automatically fill series in column a like mentioned below...
In a worksheet I have a list starting Col A being the running reference no. such as Action 1, Action 2 and so on. Each time a new action is needed the numbering increased by 1. The next column is the description of the action. This list start at row 39 of this worksheet.
This is a protected worksheet and entry of data is limited to specify cell in the list.
1. Look for the last Action Item. 2. Check if the description column (Col B) is blank. 3. If Col B is blank delete the whole row.
I'm working this spreadsheet and i want to automate of deleting the entire rows once the last two columns contains both Zero values. the worksheet cotains thousands of row to clean-up.
I want to delete a row in excel based on a condition.
The condition is as follows:
I have few rows in the excel where the columns 7,12,13,23 are same and column 24 in one row has some number and in some other row the column 24 is blank with orange color filled(the colorindex for orange is 44).
In this case I want the row with orange color filled in column 24 to be deleted.
I'm working on Outlook 2003 and Word 2000 which are not compatible. I have an Excel Sheet which are my contacts from Outlook and I want to re-work it to have only a certain category left.
I need a macro that does - search a certain column - deletes the row if it does NOT find a certain condition
Ideal would be a little pop up window to enter which category I want left.
I have some data in numaric form from range a2:f20000 which I have got as a sum from a sheet and I want if any cell (a to f) from row 2 to 20000 has sum up value blank or 0 then it deletes shift xlleft.
i have an issue i need to delete entire row if a condition is met, i need syntax if possible to delete if a cell word "begins with" a certain letter ...in this case...letter A
Is it posibile to make a macro that automaticaly delete rows based ona a condition. Condition is to delete rows that have B column value "" or zero. For example:....
I want to be able to delete certain rows based on multiple criteria. If data in the row does not meat the crieteira, it shud be deleted. I have attached the excel file sample in which I want to keep the highlighed rows and detele the rest. Its base on Origin city and Destination city combination. Eg: If Origin city="A" and Destination City = "B", I want to keep the row. Like wise for all highlighted rows. but if the Origin City = "B" and Destination City = "U" I want to delete the row.