Identify Blank Rows & Columns
Mar 19, 2008
What is the syntax that I have to use to identify whether or not an entire column or a row is blank? Specifcally I want some code where I can say if row 1 is null, or blank then delete the entire row or. if column A is blank then delete entire column
View 2 Replies
ADVERTISEMENT
Feb 19, 2013
I have a spreadsheet with columns and columns of data. What I'd like to do is identify which rows have blank/no data in all specified columns (H, K, O, S, U, W, and Y).
To clarify, I need to identify each row where all of these columns are blank (as opposed to each row where at least 1 column is blank).
View 3 Replies
View Related
Dec 28, 2011
I have this in Column A, with about 120 entries:
Company 1
Contact 1
Address 1
City, ST, ZIP 1
Phone 1
Fax 1
Company 2
Contact 2
Address 2
City, ST, ZIP 2
Phone 2
Fax 2
Company 3
Contact 3
Address 3
City, ST, ZIP 3
Phone 3
Fax 3
I want this:
Company 1 Address 1 City, ST, ZIP 1 Phone 1 Fax 1
Company 2 Address 2 City, ST, ZIP 2 Phone 2 Fax 2
Company 3 Address 3 City, ST, ZIP 3 Phone 3 Fax 3
all the way down.
I can't figure out how to record the macro to tell it to then skip the blank line, collect the next set of data, and put it in the next row. I can do it for two, but then it just replaces the first two with the next two and I lose data.
View 5 Replies
View Related
May 27, 2014
I have command button in Sheet 3 (from where I will be running the macro) and I need a macro which will delete all the blank columns and rows in the data containing in Sheet 1.
View 2 Replies
View Related
Jun 10, 2014
I have been trying to sort an excel spreadsheet to no avail. I have read mutliple posts and searched online but I can not find a solution. This is what I have. I have three columns of data. column A is an account name. column b has some insurance coverage info and may have multiple rows that go with column A. Column C has the effective date of the coverages in column B. I want to sort column A in alphabetical order but when I have tried it does not keep column B and C together with column A.
Column A Column B Column C
company 1 General Liab 5/1/14-15
Workers Comp 2/1/13-14
company 2 workers comp 2/1/13-14
company 3 crime 5/5/14-15
D&O 5/5/14-15
Fee 4/15/14-15
View 5 Replies
View Related
Sep 15, 2007
Hide Multiple rows. I have text within two columns A, D. How can I Hide Blank rows which spans two column Named Ranges, "Range1" (A1:A15) "Range2" (D1:D15). As an example:
Beginning with this:
...A......D
1.Text
2........Text
3.
4.
5.
6.Text
7.Text
8.
9.
10.......Text
11.Text
12.
13.......Text
14.
15.......Text
To this , after hiding blanks:
...A......D
1.Text
2........Text
6.Text
7.Text
10.......Text
11.Text
13.......Text
15.......Text
View 2 Replies
View Related
Jul 23, 2014
I am trying to create a macro that sorts rows based on value of 2 columns, but every time that a value changes in either of them to leave an empty row between them. Is that possible? In simple words i want to separate my rows with the empty row while sorting them out alphabetically based on two columns.
Please check my screen shots. Test 1 is my spreadsheet before the macro. Test 2 is how i need it to be after the macro. The two columns that i want it sorted out is First GDS then Rate.
View 6 Replies
View Related
Apr 17, 2013
I work with a spreadsheet every week to input values and subtotal them. These values change constantly and instead of going through and manually deleting each row in a 100+ row spreadsheet to be able to import into another program, I'm looking for an quicker way to keep my data in order but consolidate by getting rid of only the rows where both column A and B are blank.
Here's an example of what I'm working with:
5
10
15
20
50
2
4
6
8
20
This is what I need the final product to look like:
5
10
15
20
50
2
4
6
8
20
So I would like to quickly delete rows 2, 5, and 11. All of the other answers I've found only show how to delete rows based on empty cells in only 1 column. How can I quickly delete the rows where both columns are empty?
View 5 Replies
View Related
Apr 11, 2014
I currently have a spreadsheet that I had to convert from multiple rows to columns:
[URL]
Now I need a script to change the data so that each column is now in row format, (see attached spreadsheet).
View 5 Replies
View Related
Feb 10, 2014
We utilize large data sheets that can be as large as 300K in rows and 10 to 15 columns wide. Because of how we receive the data, we are forced to manipulate things so that all matching data for a record ends up on a single row. (e.g. Record#, Document Type, Husband Name, Wife Name, Wife Maiden Name, Etc.)
Right now here's how the data is received:
a
a
a
b
b
c
c
c
c
d
d
d
e
e
e
e
Using two vba scripts, we first separate the data with row spaces between the unique data as follows:
a
a
a
b
b
c
c
c
c
Then with another script, we transpose the data as follows:
a a a
b b
c c c c
d d d
e e e e
When we transpose the data, the end result starts at the top of the page and go down eliminating the original blank rows. Not a huge issue but I would like to be able to maintain the original data format of the rows so that the data matches the original sheet line for line. The end result would give me the data as follows...
a a a
b b
c c c c
d d d
e e e e e
where the vertical gaps between the letters matches the original rows. Like I said, not a huge issue since we can rejoin the transposed data to the original data fairly easily. But it would be nice if we could end up with the above format for speed sake.
The two scripts we use, one-to insert the rows and two-to transpose, take a very long time to run with the transpose script taking the longest by far. On a 30K row sheet, it will take on our systems around 30 minutes to transpose and about 15 minutes to insert rows. Because we have several columns that need to be transposed, a 30K row sheet will take at least 2 hours to complete. A 300K row sheet, that will take 10 to 15 hours to complete.
Is there any way to speed up the scripts either by upgrading to a faster CPU and or writing the scripts to preform faster?
My preferred solution would be to write (have) a formula to preform the transposition that gives me the results as noted above since formula's run so much faster than vba. Is this possible? I have tried all kinds of formulas and can not come close and of course the straight transpose function does not give me the solution I need as noted above.
I have enclosed an excel 2010 spreadsheet with 10K rows of data in rows along with the scripts I use (nothing sensitive here). The tabs at the bottom shows you the data before I transpose, then the data after it has been transposed . To speed up the scripts, I have stripped away the all the rest of the data from the original sheet except just what I need to transpose at one time. Once that is completed, we then re-join the transposed data with the original sheet. The six digit number you see to the far left of the data is the record ID number from the original data. We use this to rejoin the transposed data with the original data so that we know everything is back where it should be. (Note: The insert rows script is run on the original data and not the data you see on the enclosed spreadsheet. That is the only way we can generate unique rows with matching ID numbers. We arrive at this by taking the original data, concatenate the record ID with the column we want to transpose and add a # between the two so that we can break things back apart after the transposition using the text to column function using the # as the separator.)
The sheet I have attached is in the 2010 Macro Enabled format...(xlsm format). We use the xlsb (binary) format for the data to reduce the file size as our normal procedure and run the macros from inside that format. Changing from the xlsx to xlsb format did seem to speed up the scripts a bit and greatly improved the file performance as a whole e.g. saving and loading.
One thing I have done to speed up the scripts is to strip all the data away that is not needed for the transposition. That did work but only a marginal amount.
We are using windows 8.0 with 4G memory and your basic processor speed...e.g. nothing fancy.....just your basic stock computer. Nothing else unusual is installed or running on the computer or at the time the scripts are running.
For those of you that process large sheets, how much of a performance upgrade will we see in processing our scripts by either upgrading memory to 8G (or more or much more) and or getting a faster processor? Or have we reached the maximum script speed already? Or is this a limit to Excel.
One other issue to note: As I stated above, on the 30K row sheets, not a super problem with about 2 hours needed to run the scripts on all the data on the sheet. But on the 300K row sheets, it can take 12 or more hours to run and there are times when things 'lock up' running the scripts on sheets this size.
View 5 Replies
View Related
Mar 6, 2014
I found this great macro to use in a spreadsheet I'm trying to transpose from rows to columns, however, I need a place holder for blank cells: [URL] .....
I was able to use the macro in the last post by Ochenden but the blank cells need to have a placeholder.
How to change the macro or come up with a different script for me to use?
Attached is how I need the spreadsheet to look.
Script I used:
Sub aaa()
Dim OutSH As Worksheet
Set OutSH = Sheets("Sheet2")
Range("A:A").AdvancedFilter Action:=xlFilterCopy, copytorange:=OutSH.Range("A1"), Unique:=xlYes
[Code] ..........
Transpose_Duplicates_Examples.xlsx
View 2 Replies
View Related
Oct 1, 2008
i have created a spreadsheet to simplify our work flow, I am stuck on what is probably the easiest of the commands.
basically have rows dedicated to specific codes and the colums represent values relating to each code, all codes have a different set of values, the attached example only has a few variables but the actual worksheet will have several hundred.
the idea is the user will input the code they wish to get details on in A2 and then press the command button and it will then show (as per the after sheet in the attachment) just the relevant information for that code, so filter the code in column A and hide the columns which hold no value.
where i am getting stuck is I am not sure the best way to proceed, is it best to create the macro button to do the filter and hide or is there a better way using vlookup and a pop up window asking for the relevantcode to be inputted to to retrive the information, again understand there will be hundreds of colums and hundreds of rows and the values may be 20 or 30 colums apart for some of the Codes so this simplification is really saving the user a lot of time.
View 7 Replies
View Related
Aug 14, 2014
What is the best way to track blank/empty range cells?*Have tried 'IsBlank' but it keeps showing "False" (cell range: H7:P7, no value and spaces)
View 3 Replies
View Related
Dec 5, 2008
I am trying to count the # of rows in a spreadsheet in which there is non-blank text data in 2 separate columns. For instance, if the spreadsheet looked like the one below (dashes just for formatting purposes):
NAMES-------THIS-------------THAT
Mary-------some text--------some more text
John-------<blanks>---------just text here
Sue--------just some here-----<blanks>
Dave-------something--------something else
Adam------<blanks>-----------<blanks>
The total # of rows with something in both the "THIS" and "THAT" columns above would therefore be 2.
View 4 Replies
View Related
Jun 21, 2007
I regularly import a list of data into Excel containing employee team names, employee names, and (for these purposes, irrelevant) data. The team name is the only data in column I, and therefore I can easily pick this up an summarise it in a lookup. The employee name is always one row above it, and in column D. However, it is not the only data in column D, and each employee's records contain varying numbers of rows. How can I have Excel copy the employee name in to column J, alongside the team name in column I, but ONLY in rows where there is data in column I?
View 3 Replies
View Related
Apr 14, 2014
I am new to macro and just trying to learn. I have a spreadsheet with 20000 rows and 8 columns. I am trying to identify equal rows based on the values of columns C, D, E and F. then I need to separate equal bunches with a blank row. Then I need to copy the ID number from the first cell of column B of each bunch and paste it for the rest of the rows in that bunch. I have written the following code but this does not put the ID of the first cell in a bunch for the rest of the rows in that bunch.
[Code] .........
View 10 Replies
View Related
Apr 14, 2009
It's a time sheet that I need to have whatever data is listed in column E to be listed starting in cell C27 but only once even if it's listed several times. In cell D27 I need the sums to match the data to it's left with the values from above in column D. I've used fill colors to help show my intent. I would also like it to keep track of remaining vacation time by recognizing the word 'VAC' from column E and subtract the value from it's left. This value is shown in cell J26 as '46hrs REMAINING'.
View 4 Replies
View Related
Jun 1, 2012
I have two columns of B2 and C2 data in the same worksheet and want to identify duplicates in the columns and return a value of true or false in column D. The formula I have been utilizing is:
=IF(ISNA(VLOOKUP(B2,$C$2:$C$5000,2,FALSE)),0,VLOOKUP(B2,$C$2:$C$5000,2,FALSE))
However, i receive a #REF# return in D. What am I missing ?
View 6 Replies
View Related
Apr 9, 2014
I have a macro-routine that generates a table of all sheet-headers (+/- 100-120 sheets) in a workbook. It's crusial that all headers - row("1:1") - have the same values in respektiv columns -so I have this routine to check that this really is the case, before new prosess. The table is rather huge - so I should som way or another identify the columns with more than one value (f.ex back-ground-color in column-top-cell). In this case I must edit and correct the header, and run my routine once again - until all headers are the same
Table is plased in Sheetc("HeaderCheck")
My routine works, but I dont know how to fix this mark-up stuff.
View 3 Replies
View Related
May 18, 2007
The following code takes the selected item from a listbox and populates another listbox with the item. The problem is that only the item from column 1 is populated to the other listbox. How can I populate the other listbox with the items from both column 1 and column 2?
Private Sub cmdSelToExc_Click()
Dim i As Long
With Me.lstProducts
' Copy all selected items, then delete.
For i = 0 To .ListCount - 1
If .Selected(i) Then
Me.lstExclude.AddItem .List(i)
End If
Next j
Next i
For i = .ListCount - 1 To 0 Step -1
If .Selected(i) Then
.RemoveItem i
End If
Next i
End With
End Sub
View 2 Replies
View Related
Mar 14, 2008
I have two spreadsheet in which I am looking for duplicate customer names.
1st - "Customers"
2nd - "Orders"
In column A of my Customers spreadsheet I have the following formula
=IF(ISERROR(MATCH(E2,Orders$D2:D1000,0))=FALSE, "Y","N"). This allows me to see if a name in my Customer spreadsheet (column E is a field of names) is also in my Orders spreadsheet (column D is a field of names). My end results is either a Y indicating a duplicate or a N for no duplicates.
What I am looking to do next is to place in column B of my Customers spreadsheet the date that coincides with the duplicating customer name. Sorry to be confusing. If a customers name is found in the Orders spreadsheet I need to know what date has been given to this customer (column L in the Orders spreadsheet contains the date information).
However, on numerous occasions a customers name is found in the Orders spreadsheet more than once meaning there may be more than one date which needs to be placed in column B of my Customers spreadsheet.
View 9 Replies
View Related
Jul 9, 2013
I am working on a project, I have three different lists that I want to compare and I want to identify in 3 separate columns which titles are found on which list.
For example:
Title List 1List 2List 3
ACAROLOGIA x
ACCIDENT ANALYSIS AND PREVENTION x
ACROCEPHALUS x
ACS CHEMICAL BIOLOGY x x x
ACS CHEMICAL NEUROSCIENCE x x x
ACS COMBINATORIAL SCIENCE x x
ACS MEDICINAL CHEMISTRY LETTERS x x
ACS SYNTHETIC BIOLOGY x x x
View 4 Replies
View Related
Jul 10, 2013
So here I have two columns Column 1 with repetitive values of some 10000 records Column 2 with unique values of 100 records I want to compare Column 1 and Column 2, identify the values in Column 1 that match with Column 2 and highlight them. Conditional formatting for duplicate values doesnt work because Column 1 has repetitive values.
View 6 Replies
View Related
May 25, 2006
I have a macro that performs Index&Match formulae on another workbook. This leaves me with some #N/A results. I then require the macro to delete all rows that contain #N/A. I have tried to identify these via
If Range("E" & myLoop).value = "#N/A"
and
If Application.WorksheetFunction.Isnumber(Range("E" & myLoop).Value) = False
but each one gives me a Run Time Error 13 (Type Mismatch) because, even though the results are now values and not formulae, it sees '#N/A' as an error (Error 2042).
View 3 Replies
View Related
May 30, 2013
I have a pivot table and perhaps that isnt the best way to do this. (Sample attached). Ultimately I need to display two columns only:
Application (ColA) Business (ColC)
There are three columns of data.
Applications (ColA) Usage(ColB) Business (ColC)
There are multiple instances of the same application in ColA, ColB has usage =true or blank and ColC has multiple instances of the same business.
Based on the count of Application in ColA, and the count of Usage =True, I need to return the Business with the MAX count.
Note: the usage cannot be a filter, it must be a count.
View 1 Replies
View Related
Apr 27, 2014
I have data (e.g. PPL0106AU) in columns A (Rows 2 to 104) & C (Rows 2 to 303) and need to identify which entries are in BOTH columns.
I've entered in column B: =IF(MATCH(A2,C$2:C$303),A2,"No")
This formula is resulting in a duplicate of column A in column B.
View 7 Replies
View Related
Sep 2, 2013
I have these kind of matrices (below) and I'd like to identify unique values specific to different groups of columns:
[Code] .........
For instance, in the example above, if we decide that A, B, C are "Group 1" and D, E, F are "Group 2", and that the values in rows 1, 2, 3 are independent (i.e., "x" in "1" is not comparable to "x" in "2", etc):
- In condition (row) 1: "x" is a specific value only found in Group 1
- In condition 1: "y" is a specific value only found in Group 2
- In condition 2: "x" is a value found in majority in Group 1
- In condition 3: no specific value can be associated to Group 1 or 2.
What I would like to get is a measure of whether:
(1) there are values over-represented in one of the groups, or 100% specific to one group.
(2) what are these values
(3) if multiple values are a bit tricky, then: what is the value which is the most over-represented in one group compared to the other (the maximum being 100% in one group and 0% in the other)
View 1 Replies
View Related
Nov 20, 2013
I have a (phylogenetic) matrix with a species in each row, and morphological character in each column, scored as 0, 1, 2, 3 or 4 for each different species, so something like the following but much bigger:
Character 1 Character 2 Character 3
Species A 1 0 1
Species B 3 2 2
Species C 1 2 0
I want to identify the minimum combination of different columns (i.e. their values, but also which columns) that make a particular row unique.
View 14 Replies
View Related
Nov 3, 2006
i have a series of colums in which i have a formula for checking if each proceding row has the same value in the cells above ie duplication. i am using the following formula
= if(and (C4=C3),(D4=D3),(E4=E3)),"yes","") although this seems to work ok, some of the cells in colums D & E are empty.
what should i do to check for this.
what i am attempting to do is check for duplicate rows where the row is only a duplicate if the previous row is identical.
View 3 Replies
View Related
Sep 4, 2007
I have two sheets with many rows and about 8 columns. The second sheet is some of the rows copied and pasted from the first sheet. I have been asked to mark on the first sheet those rows that have been copied to the second sheet.
I need to check that the entire row matches before somehow making the corresponding row in the "original" sheet stand out.
Unfortunately, there is no unique identifier that I can search by. I have tried concatenating all columns into a new column on each sheet and then using MATCH but I get #VALUE! error.
View 9 Replies
View Related