Compare Cell Contents In Different Columns Then Fill Neighbouring Cells
Jun 9, 2014
I have two sheets:
- sheet 1 ('current')
- sheet 2 ('31May')
The data in column C is the same, although sorted differently and can't be re-sorted to be the same. Where the data in column C is the same in both sheets, I want to fill columns A and B into sheet 1.
View 4 Replies
ADVERTISEMENT
Nov 9, 2009
I have 2 columns, the second column has some empty cells in the end of the column
What I would like to do is to fill in those empty cells but only as many as the filled-in cells in the first column
(I have already tried the specialcells(xlCellTypeBlanks) but that did not work as the empty cells are not always "blank" as well)
View 10 Replies
View Related
Oct 19, 2012
I am trying to compare two cells and if they match then I want to fill in a list on sheet one from sheet two.
I have the absolute working when I compare one cell to one cell, but I can't get it to compare one cell to a range of cells (two weeks of days)
Here is the absolute one I have working:
=IF(C1='Data Sorted'!A1,'Data Sorted'!A2,"")
Here is what I tried that doesn't work:
=IF(C1='Data Sorted'!A1:N1,'Data Sorted'!A2,"")
View 6 Replies
View Related
Dec 30, 2013
I have attached a workbook stating my problem.
file1.xlsx
View 10 Replies
View Related
Jul 3, 2014
I am currently using this Code to search column1 for a Key Word that is entered into textbox "Kunde" on my userform.
[Code] .....
What i would really like to be Abel to do is :
Search for the cell in column1 with =Kunde.Value
Clearcontents of this cell and the 2 adjacent to the right.
i.e. Word is found in A7
Cells A7:C7 contents are cleared and fill Color returned to default colorindex 0
View 3 Replies
View Related
Mar 13, 2009
So I have a spreadsheet that has a Title in Cell A1, then entries in B1, D1, F1, H1, J1, etc... with empty cells between.
What I would like to do is copy those entries to the right, i.e. B1 into C1, D1 into E1, F1 into H1, but all the way along because in my master sheet there are a lot of columns.
View 11 Replies
View Related
Jan 13, 2009
I want cells containing the same contents to fill with the same color. But I want different colors for each matched set. I know I can match text to a color, but I may have 100 possible items and to create matches for all 100 would be time consuming and there are not enough colors. I just want random colors picked by excel to create some visual separation to similar cells.
View 9 Replies
View Related
Apr 30, 2014
I have a spreadsheet with 10 columns which are for tags for products. Some columns are filled in for 10 products and some are not. For instance, product 1 has 7 tags while product 2 has only 2 tags and so on. Now what I am looking to do is combine all the tags for each product with a "," inbetween each one. The problem is if I just use a simple =A2&","&B2&","&C2 etc formula is that if there are only 2 tags then I get 8 ","s. I also tried it with an IF statement but by the time I was done nesting items I became cross eyed and said there has to be an easier way to do this.
I have create a spreadsheet with the data and the result that I typed into the "result" column.
View 3 Replies
View Related
Apr 30, 2013
I have an excel spreadsheet with multiple columns of options.
In column A, I select either "yes" or "no" to activate other columns.
In column B, I have, let's say, lease terms; 12, 24 & 36.
I'm trying to find a formula that I can enter that will take all the columns I select as yes, and tell me if the lease terms match up.
So, if I select yes in cells A4 & A13, are the lease terms in B4 & B13 the same...do they match?
View 5 Replies
View Related
Jun 30, 2006
way to automatically hide a row or column based on a specified cell.
Or even something general like: Hide all rows with cells evaluating to #n/a.
View 9 Replies
View Related
Sep 8, 2007
I have two columns that use data validation. Column-F uses a dynamic named list in the validation and column-G validation is set to allow a decimal entry only. I need a third form of validation to compare the two values and an message when there is an error.
If F1="None" then the required entry in G1 must be 0 (zero). If F1 <> "None", then G1 entry can be any value greater than zero.
What I would like is a message box to pop-up explaining the error when F1="None" and G1>0.
I'm using a helper column-K that concatenates the cell values (in F:G) into a single string that I can check. Not having much success, but what I've tried so far is:
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Dim myrange, mycell As Range
On Error Resume Next
Set myrange = Sheets("Copper Data").Range("K10", Range("K65536").End(xlUp))
For Each mycell In myrange
If mycell.Value = "No Scrap0" Then MsgBox ("You entered a scrap reason of 'No Scrap' and quantity of 0")
Next mycell
End Sub
It either fires all the time if the helper cell string is "No Scrap0" or it doesn't fire at all if the string is "NoScrap1" (where "1' can be any number).
Currently trying to build this, but my fledgling VBA knowledge has me hamstrung. I'm getting an error of "Next without For').
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Dim r, c As Range
Dim note As String, Response As Long
note = "Data Entry Error: Scrap Quantity cannot be greater than zero with a reason code of No Scrap." & vbLf & vbLf & _
"Please check the accuracy of your entries."
View 9 Replies
View Related
May 28, 2014
Data file with few columns. There are groups of similar ID numbers in Column J. For a group of similar ID numbers in consecutive rows there is only one row that has a number greater than 0 in its Column L cell and the rest of the cells of Column L for that set of similar IDs is filled with 0s.
First for that unique ID group I need to find out which row is it that has a value greater than zero in its Column L cell.
Then I need to use that value to fill the rest of the 0s in Column L corresponding to that set of Unique IDs.
The process continues with identifying similar IDs in Column J and this time doing the same thing for their Column M. I have attached a sample file that shows the data and how the results need to look like.
See here Fill Cells.xlsx
View 1 Replies
View Related
Jan 13, 2014
I am trying to create a formula that is able to calculate an end result based on the cell contents of 3 columns, the results are predefined in 3 other columns, here D, E & F
For example:
Column A Column B Column C Column D Column E Column F Column G (Results)
Royal Mail 1 100 2.8 2.3 1.2
Royal Mail 2 100 2.9 2.4 1.3
Royal Mail 3 100 3.0 2.5 1.4
DPD 5 200 4.5 2.8 1.5
DPOST 1 100 1.2 3.2 1.7
I am trying to create a calculation that in Column G will work out, IF Column A=Royal Mail AND Column B=1 AND Column C<=100 THEN Answer is [@[Column F]], IF Column A=Royal Mail AND Column B=2 AND Column C<=100 THEN Answer is [@[Column F]], IF Column A=Royal Mail AND Column B=3 AND Column C<=100 THEN [@[Column F]], IF Column A=DPD AND Column B=5 AND Column C<=200 THEN [@[Column E]], IF Column A=DPOST AND Column B=1 AND Column C<=100 THEN [@[Column D]]
Here are an example of what I have tried, amongst many...
=IF(AND(AND([@[Default Post Postal Service]]="Royal Mail"),AND([@[Default Postal Format]]=1),AND([@Weight]<=100)),1,0) Everything is zero.
View 4 Replies
View Related
Jan 12, 2012
I frequently review DAT files. These DAT files use a variety of characters as delimiters. I'm trying to devise a macro that will perform a text-to-column operation, using the content of a specified cell as the delimiter.
Here's my code, which uses - (ASCII 0254) as a delimiter:
Code:
With Sheet1
Range("A1", ActiveCell.End(xlDown)).Select
Do
[Code]....
Instead of having the delimiter hard-coded, I'd like my macro to use whatever character I enter into Sheet3.Range("i5") as a delimiter. That way, I can easily change my delimiter character as necessary.
View 4 Replies
View Related
May 2, 2008
I have created a desk planning spreadsheet in excel. Each week a mailmerge sends out an email to everyone in the office asking them to confirm when they will need a desk in the next week.
As the normal employee doesnt get involved in desk planning I want them simply to state whether they will be in the building or not by entering "GH" (our building) in a cell under each day in the email they get sent.
When the reply comes in we select the cells from the email and then paste them into the desk planning spreadsheet.
-----
WHAT I NEED TO DO:
Select some cells (must be in the same row - that we have just pasted in).
Press a button on the Worksheet labelled "Auto Assign Desk", which does this:-
For each cell that contains "GH", replace with the right-most cell to the left of the selection that starts "GH_"... (this is the start of a unique desk reference (GH_1_1, GH_1_2,etc.)
-----
This will assign the employee to the desk they were sat at last, when they are in the office next week.
View 7 Replies
View Related
Jun 30, 2009
I have a slight conundrum that goes as follows:
If in a given row, the cell in column A is empty, but the cells in columns B and C have values--would it be possible to automatically fill in the empty cell with the same value of another rows column A cell, if both rows share the same value (nb: not case sensitive) in the column B and C cells.
For example:
If one row, say Row 44, contained the following:
Column A Cell =
Column B Cell = sunday
Column C Cell = dog
and another row, say Row 10023, contained:
Column A Cell = Walk
Column B Cell = Sunday
Column C Cell = Dog
How would I go about automatically filling in Row 44's column A cell with the value "Walk", as both rows columns B and C cells match up.
I should mention that I am dealing with a sheet with over 30'000 rows, so it would be incredibly time consuming to find matches and input the missing value directly.
View 13 Replies
View Related
Mar 28, 2014
I am trying to modify the macro listed below for the following example. It would work when I have only numerals in the cell but this new query, the cell has both letters and numbers.
I want to compare column "M" from worksheet one to column "B" in worksheet two. If the information matches, then copy the value adjacent from worksheet two column "A" to worksheet one column "L".
Here is the macro that worked for me using a search of only numerals.
figuring out why the data doesn't copy?
Macro:
Sub merge_accession_PS_rad_productivity()
Dim rng2 As Range, c2 As Range, cfind As Range
Dim x, y
With Worksheets("Imaging_Summary")
'N4=Accession on Imaging Summary worksheet
[Code]....
View 9 Replies
View Related
Jun 2, 2009
I'm alittle new to excel and MrExcel website. I have a spreadsheet that im trying to get a formula to work as below. If anyone knows how to get this to work please help! Thank you.
My spreasheet has the following:
Sheet1:
Column B Column G
1 test 1
2 center 2
3 school 4
Sheet2:
Column B Column G
1 work blank
2 school blank
3 home blank
I'm trying to find the value from sheet2 cell B2 (school) in sheet1 column B and then when it finds that, I need it to copy the data from the Corresponding sheet1 Column G cell to sheet2 Column G cell.
View 9 Replies
View Related
Feb 19, 2010
I need a macro that will look - this is hard to explain so will prob do wee diagram too but basically the macro nees to start looking at sheet2 A5 (the numbers start at A5 before that is text) see if it is greater than Sheet1 ColumnA & Less than Sheet1 columnB if the number is then I need Sheet2 ColumnD inserted into sheet 1 ColumnG. There is the text END on all columns on both sheets for the loop, the reason for the loop of course is there could be 100 lines in sheet2 ColumnA & I must look at all lines in sheet1 to see if it is greater than columnA and Less than ColumnB and if it is populate Column G.
Sheet1
Column A ColumnB ColumnG
Row 11 4000 4999
Row 12 5000 6099
Row 13 6100 7400
ETC
END END
Sheet2
ColumnA ColumnD
Row5 5130 134.58
Row6 6900 6400.00
ETC
END END
After the macro the result would be
Sheet1
Column A ColumnB ColumnG
Row 11 4000 4999
Row 12 5000 6099 134.58
Row 13 6100 7400 6400.00
END END END
Sheet2
ColumnA ColumnD
Row5 5130 134.58
Row6 6900 6400.00
END END
View 9 Replies
View Related
Jan 21, 2010
this is in reference to a question I asked some time ago in which I was given the following: =IF( COUNTIF(SHEET1!$A$1:$A$1200,SHEET2!A1),SHEET2!A1,"")
To summize as this is not quite working, I have two worksheets and in Column A are id#s. Worksheet 1 has100's more rows of data than Worksheet 2. I need to find the unique ids from column A in Worksheet 1 that match Unique IDs in worksheet 2.
I need to copy the row of cells from worksheet 1 where the unique id equals that u.id in worksheet 2. That row needs to be copied to Sheet 2 that has the same unique id, and after the pre-existing cells which are already present.
So for instance: if Sheet1 A100 = Sheet2 A24, then copy row A100from Sheet 1 and paste it to Row A24 of SHeet 2 start with the first empty cell- just say Sheet2 G24 as an example.
Using the formula I was given before, it finds matches, but the pasted rows are off. If the match occurs with Sheet 1 A450 and Sheet 2 A36, it will copy the value from ROW/SHeet 1 A36 instead of ROW/Sheet 1 A450
View 9 Replies
View Related
Jan 19, 2008
I have this code that compares two columns on two different sheets when it finds a match it then puts the match on that sheet your running it from in my case sheet 2. However i want to change this slightly and im having a hell of a time. I want to match but when tha match happens i want it to copy the cell next to the match.
Sub Find_Matches() ...
View 3 Replies
View Related
May 27, 2008
In a worksheet I retrieve data from a SQL query. Now I have to add 5 different calculations per row and each calculation will be stored in a new cell (so 5 columns will be created)
I want to do this with a loop macro and calculate this till the last "filled" row. The number of rows differs every month.
What loop code should I use and can somebody give me an example of the VBA code.
Note that some formulas contains nested If-functions.
View 6 Replies
View Related
Jul 6, 2007
I have a master spreadsheet containing 4 relevant fields, 'Manufacturer', 'Product', 'Version' and 'Type'. This contains all possible variations of 'manufacturer', 'product' and 'version' that can occur in the organisation.
The type field shows how the particular item is going to be processed, either 'automated', 'manual' or 'non'
This is a computer generated spreadsheet, apart from the 'Type' field which we've entered for each one individually, as are the user spreadsheets which dont yet have the 'type' field.
This is a large list of around 7000 items
I then have a multiple spreadsheets (one for each user, totaling around 1200) that has a list of a couple of hundred items that are relevant to the user which contains 'manufacturer', 'product' and 'version'.
i need to sort these out quickly by comparing the sheet to the master spreadsheet so where 'manufacturer', 'product' and 'version' match up with the masters record it automatically removes the the 'non' type of item from the user sheet and placing either 'automated' or 'manual' in a new 'type' filed where appropriate
View 3 Replies
View Related
Jul 20, 2009
I would like to fill my dropdown box with the contents in a selected column (removing duplicates).
View 13 Replies
View Related
Jan 31, 2014
I am a locksmith and attempting to write a spreadsheet app. for my line of work. The output page will use columns A-G and rows 1-?10000? depending on the size of the system. If a 5 pin system is requested then columns A+B will be blacked out. 6 pin system A is blacked out. 7 pin system nothing blacked out. Also, if any cell matches the master key that was input, that cell is filled with red. I know, confusing.
Basically, I am trying to remove the blacked out columns automatically, and to remove the enitire row is any cell in that row is filled with red. Then to remove blank lines.
View 2 Replies
View Related
Feb 24, 2014
I wanted to enter value in sheet1 on A1. Columns in sheet2 from B1 until the value entered in sheet1.A1 should be automatically filled.
E.g.
Sheet1.A1=5, then Sheet2.B1=1, Sheet2.B2=2, Sheet2.B3=3, Sheet2.B4=4, Sheet2.B5=5.
if Sheet1.A1=3, then Sheet2.B1=1, Sheet2.B2=2, Sheet2.B3=3.
if Sheet1.A1=7, then Sheet2.B1=1, Sheet2.B2=2, Sheet2.B3=3, Sheet2.B4=4, Sheet2.B5=5, Sheet2.B5=6, Sheet2.B5=7
etc.
View 2 Replies
View Related
Sep 11, 2013
How can I let cell F5 for example contain both the texts or contents of cells A1 and B1? Is there a function that can do that purpose?
View 5 Replies
View Related
Dec 14, 2013
I am working on a sheet where I want the contents of cells D1:D10 appear if cell A1 has a text in it and the contents of cells D1:D10 disappear if cell A1 is blank. What is the right conditional formatting formula for this.
View 3 Replies
View Related
May 27, 2013
I do not have excel or an xls for a sample, I will try and restate the question.
In Cell A1 It will be used for copying the contents of and pasting the completed information into web browsers.
In Cell A1 You will find This information contained and formatted in one cell alone.
Figure-1
A1=
Information About Company
Brief Story About Company
Product Name: (X)
UPC Number: (Y)
Serial Number: (Z)
Terms Of Sale
Etc
End Figure-1
I want to essential Modify (X)(Y)(Z) using different cells one for each variable. "All completed information will be found inside of A1"
Having Cell B1-B9 Being used as labels "Product Name" "UPC Number" "etc" and using cell C1-C9 to input variables for = (X)(Y)(Z)(ETC)
In reality from cell A1 will change dynamically, but some information will need to stay constant.
Every thing In B column will just be labels.
Every thing In C will be for variables.
View 1 Replies
View Related
May 16, 2007
I want to create a macro that will run through a column and assign a name to each cell in that column that reflects the contents of another cell within each row.
for example, cell A1 = "Gerry", A2 = "Rob", A3 = "Ryan"
I would then like the Name of B1 to be "Gerry", B2 to be "Rob", etc (but to retain original contents).
Is this possible using VBA?
View 3 Replies
View Related