Removing Rows With More Than One Condition
Mar 21, 2007
Currently i have this to delete entire rows that have cells which contain any words with "Security Market" in it.
How can i extend this to include many more variables like e.g. " Total" "ABC" "XXXX"
Dim rag As Range 'Rows with "Security Market"
Dim sec As String
sec = "Security Market"
Do
Set rag = ActiveSheet.UsedRange. Find(sec)
If rag Is Nothing Then
Exit Do
Else
Rows(rag.Row).Delete
End If
Loop
View 5 Replies
ADVERTISEMENT
Mar 19, 2008
I was wondering if anyone had a formula or Macro suggestion to remove rows with no information. I made a pivot table that feeds to another sheet in order to make it more user friendly. The only thing is when there is no information I have formula to returns a zero. I would rather the row be hidden.
View 9 Replies
View Related
Apr 14, 2013
Is there way, short of creating a macro, to have duplicate rows deleted in a spreadsheet?
View 3 Replies
View Related
Jan 27, 2010
I have a report that I import from a program, but every time I export to excel, it skips lines. What would be the code to remove empty rows from it?
View 2 Replies
View Related
Mar 10, 2006
I have a report that pulls data from another worksheet in Range A26:J58.
What I want to be able to do is assign a button for printing the report but
before printing from A1:J70 removing or hiding any row in the A26:J58 range
where there is no data. The range is filled from row 26 down so it is not a
random fill.
Also, I want to save this workbook as a template so that it can be used over
again, so I guess it would not be good to delete the rows in the range
otherwise I would have to recreate them.
View 14 Replies
View Related
Aug 31, 2007
After importing a text file I use a macro to format it, but one part I can't figure out is how to delete the first two empty rows. I need to delete them because the cells in each of these rows are merged together which complicates data manipulation. As you would expect, the row number will be different with each import. Can anyone help with code that would accomplish this?
View 9 Replies
View Related
Mar 30, 2009
I've got a spreadsheet that uses about 2200 rows and about 15 columns. However, when I try to insert a column, it freezes up the application. My assumption is that this is caused by the fact that there are in excess of 65,000 rows. When I try to highlight those 63,000 rows and delete them, the system freezes up as well.
These excess rows are unnecessary and I'm sure add to the file size.
Running Windows XP with Excel 2003.
View 9 Replies
View Related
Jun 21, 2008
I have an imported report in a spreadsheet. It imports to three columns. I need to check each row in column A for three seperate criteria and delete the rows I don't need. I need to delete blank rows and check next row for page header info. Delete these and next rows to next blank cell. Check next row for page header and not delete if not page header. Several rows down will be a cell with 23 blank spaces before the word Reg: and sometimes other words past this but always this first. This row is to be kept. I looked at the FAQ's example of Deleting but I don't think it will work. I also need to put a key word in column A at a point where I want to stop. This report is a couple thousand rows long so a VBA procedure would really save time. I have a procedure I use to check for two zero's in two cells that hide these rows but I couldn't modify it to work on this report.
View 9 Replies
View Related
Oct 10, 2009
I want to create a macro that will cut and paste a worksheet out of an existing workbook and tidy up the table by removing all rows where there is no value in one of the fields (product or part number for example).
View 8 Replies
View Related
Jan 24, 2013
removing empty rows from my set of data.
I have a big set of data that I'm copying and pasting into excel. When I paste it there are 2 empty rows between each line of data. I want to remove these empty rows, without affecting the data. I tried 'Go to special...' and deleting all empty cells and stuff but I couldn't get it to work. The problem is that there are blank cells in some of the rows that I want to keep. When I try to remove the blank rows, I also end up removing rows of data that I want to keep.
I've made an example for you to try and explain it better - attached.
remove all of the rows that are completely empty, but leave any row that has any data in it (at any point), that would be awesome!
View 4 Replies
View Related
Feb 2, 2006
Is there a quick way to remove blank rows quickly. I have a spreadsheet with over 8500 rows but some are blank.
View 8 Replies
View Related
Jan 25, 2014
I'm trying to remove duplicates without deleting the rows they were in (instead just being left with blank spaces).
For example Column A might look like this:
Column A
1
1
1
1
2
2
2
3
I need it to look like this:
Column A
1
2
3
How I can delete these duplicates without doing it one by one?
View 1 Replies
View Related
Feb 28, 2008
I have an excel spreadsheet with approximately 10000 rows. There are approximately 10 columns...
Column A - person's ID number
Column B - name
Column C - Street Address
Column D - City
Column E - State
etc...
It being such a large list there are many many duplicates (it was pulled from a bunch of different excel spreadsheets and combined into one via copy and pasting one document into the other).
I figured out a way to have excel highlight the duplicates in a different color... but scrolling through 10k people and deleting the duplicates is obviously very tedious (approx 40% of the spreadsheet is duplicates).
Is there a way to sort out the duplicates (via their ID number, column A) so that there are no repeats? I want to get rid of the 2nd/3rd/4th (etc) occurance of the person's information but I was to obviously keep the first occurance.
I tried using Advanced Filter but I must have done something wrong because it shrunk the list too far down.
View 9 Replies
View Related
Aug 28, 2006
I have to download a report through SAP and have written some pretty basic stuff to automate the formatting process, however, i still have to manually remove blank rows. I would like to be able to add the removal of theses rows as part of the code, one of the main problems that i see is that i run this report every week and the empty rows are not necessarilly in the order every time.
View 4 Replies
View Related
Jul 12, 2012
I have a workbook with a Pivot Table full of user data and security reports. The table is structured in a way that shows, numerically; each username and how man roles are assigned. I need to remove the username/row combo's that are listed as 1 or less. Obviously if I simply highlight the fields I want to delete it won't work. How would I go about removing such rows?
View 2 Replies
View Related
Dec 10, 2008
I have a single spreadsheet with a few columns but hundreds of rows. Each row is a property reference (with other data such as address in the columns) with a type of charge in column J and the amount in column K. I'll try to replicate below ...
A B ....... J K
Prop1 Prop1Address Rent 100
Prop2 Prop2Address Rent 150
Prop3 Prop3Address Gas 70
Prop4 Prop4Address Water 60
Prop4 Prop4Address Rent 200
Prop4 Prop4Address Elec 80
Prop5 Prop5Address Service 90
I want the sheet to display a property on a single row so would look like as follows ...
A B ....... Rent Gas Water Elec Service Total
Prop1 Prop1Address 100 100
Prop2 Prop2Address 150 150
Prop3 Prop3Address 70 70
Prop4 Prop4Address 200 60 80 340
Prop5 Prop5Address 90 90
View 9 Replies
View Related
Dec 11, 2013
I have 5 worksheets that I currently have to add information to and cut/paste information from one to another. The initial information stays the same but I have to cut and paste it into one of the other worksheets based on wether or not we; need to decide on a job, are working on the job, lost the job, won the job or the job is complete.
I would like to create one master worksheet where the information can be entered with a drop down cell stating the status of the job (listed above). I created the master tab and linked the 5 subordinate tabs using an IF formula, but how can the subordinate tabs filter or sort the references and organize them on the top of the page rather than leaving a bunch of blank rows (because the info in these blank rows went to a different subordinate tab)? I want to enter the info in the master tab and simply change the pull down cell to change which subordinate tab the information shows up on. This should allow me to print the subordinate tabs as reports without having to manually cut and paste the info or filter it, correct?
View 5 Replies
View Related
Apr 28, 2014
I have a long grocery order list and only choose about 100 items out of 1000. I would like to send it to the store with only the items I need. There are several category headings throughout the list which I would like to keep...like Produce, Meats, etc. The list total dollar amount is automatically updated as I enter the amount of the items I need. I just have a lot of unused items (10) pages worth.
View 2 Replies
View Related
Nov 8, 2011
I have several sheets with about 250,000 rows per sheet.
But, even I sort by Column A, there are STILL hundreds or rows that are total blank interspersed down the page . . . I can't autofilter for blanks because there is too much data . .
How can I get rid of them?
View 2 Replies
View Related
Jun 21, 2006
Need to find out how I can restrict a worksheet to show only the columns and rows that I want. For example, I want to show columns A to H, and rows 1 to 25, and nothing else - I don't want there to be a column G, or a row 26, just blank grey space. I know it's possible, because I've seen it done : D . But the closest I can get to is: View > Page Break Preview, which isn't quite what I'm after.
View 2 Replies
View Related
Jul 11, 2014
I have this spreadsheet that I am creating schedules for my employees since our scheduling software at work is horrible to work with. It calculates total hours for each employee at the far right of the rows, and calculates total hours for each day in the columns. The formulas that calculate the hours for each day is set up to automatically deduct 30 minutes from a shift, for lunch, if they're scheduled for more than 5 hours (the gray shaded employee rows are for managers and that only deducts 30 mins if they're shift exceeds 8 hours).
I'm familiar enough to put somewhat complex formulas together, but I don't understand it enough to always make them work correctly. What I'm wanting to be able to do is add or subtract entire rows (add new employees or remove old), and have my formulas for calculating the total hours to still work. Right now if I delete a row the cell with the formula in it says #REF!. I can fix this by going through the formula and manually deleting everything in that contains those other cells, but the formula is huge, and it's pretty tedious going through the whole thing when it feels like there should be a simpler way of doing it.
TLDR: I want to be able to add/remove a row and have my cells currently on row 36 update the formula correctly.
View 3 Replies
View Related
May 26, 2014
I am trying to create a straight column list that can take the rows and columns of a table, and list only the nonblank items. The formula I am using only seems to work with one column, not multiple.
Formula:
[Code] .....
View 12 Replies
View Related
Aug 1, 2012
I have a sheet in an excel workbook which I export to a separate file and then save as a text document, I need to remove the tabs in this file, however the file (example attached) needs to be in a certain format to be imported into a piece of equipment which has a proprietary file format. Part of this format is the 2nd row and 5th row must remain present and empty.
[URL]
View 4 Replies
View Related
Sep 25, 2012
I would like an easy/fast way cut an entire row of data from one worksheet ("Open Work") to another ("Closed Work"). Each worksheet has a matching Header Row from column A - N. In "Open Work" I have column "K" with various values, but I'm looking specifically for the "CLOSED" value. If a cell in column "K" = CLOSED, I want to cut the entire row and paste it into the other worksheet "Closed Work".
That was a no-go! It copied limited rows AND duplicated them.
VB:
Sub copyrows()
Dim tfCol As Range, Cell As Object
Set tfCol = Range("A2:A9") 'Substitute with the range which includes your True/False values
For Each Cell In tfCol
[Code] ......
View 6 Replies
View Related
Apr 10, 2014
I have an excel file with thousands of rows and I'm trying to pull certain data from one tab to another. In the example, I want to pull all Listings that are "Open" (I know, just filter), but if the listing is "Open" I want to pull all of the other statuses it once had as well in the new tab. Notice how a listing can have multiple statuses.
I was thinking I could filter by Status (Open) and then do a vlookup (using the listing number as the lookup number), but it doesn't work.
View 4 Replies
View Related
Oct 6, 2008
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.
View 3 Replies
View Related
Dec 15, 2009
I want a macro to delete the entire row based on the value in Column Q ....
View 14 Replies
View Related
Jan 18, 2012
I have data in the format below. I'm looking for a piece of code that will look down column B and if there are 30 rows in which all the values are zero then delete all rows from row 1 to the last row of those 30 rows.
Input_data AB106/01/2012 13:03:170206/01/2012 13:03:1816306/01/2012 13:03:1916406/01/2012 13:03:2016506/01/2012 13:03:2117606/01/2012 13:03:2224706/01/2012 13:03:2316806/01/2012 13:03:240906/01/2012 13:03:259.51006/01/2012 13:03:26191106/01/2012 13:03:27211206/01/2012 13:03:28161306/01/2012 13:03:2981406/01/2012 13:03:3001506/01/2012 13:03:31571606/01/2012 13:03:32801706/01/2012 13:03:331091806/01/2012 13:03:341331906/01/2012 13:03:35156
View 1 Replies
View Related
Apr 21, 2014
I want to get some blank rows in a worksheet after certain characters.i have some data in a sheet. at the end of each cluster of data it ends either with 1-0 or 0-1.
if excel finds 1-0 or 0-1 at the end of a bunch of rows, it should add 5 blank rows under it.then it should search for the next 1-0 or 0-1
If data ends on A25 where you find 1-0 or 0-1 then add 5 blank rows under it from A26:A30,likewise it should be given till it reaches the end of the range.range can be defined as A1:A1000
View 4 Replies
View Related
Nov 2, 2007
I need macro to perform the following steps. I have also enclosed the image of the file for reference.
1)I need to move or copy the data in sheet one to sheet two.
2) In sheet two I need to select customer BBBB and delete all the rows beginning with PO# of 17, 18, 46 or GL4.
3) finally I want to delete all the rows in the sheet which are not equal to class Invoice. (Presently I do this using custom filter as "doesnot equal" = Invoice") ..
View 11 Replies
View Related