Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Check the two different cells in the same row
Hi all,
Could anyone tell me how to check all cells of the same column by the following conditions: 1) if the cell (D5) is blank and the cell (A5) is not blank, then fill data into D5 2) if the cell (D5) is blank and the cell (A5) is blank, then no need to fill anything Thanks for in advance. Tlee |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Check the two different cells in the same row
It is simplier just to move a into d if a is blank or if a is not blank.
sub CheckColumns RowCount = 1 Do while Range("A" & RowCount) < "" if Range("D" & RowCount) = "" then Range("D" & RowCount) = Range("A" & RowCount) end if RowCount = RowCount + 1 loop end sub "tlee" wrote: Hi all, Could anyone tell me how to check all cells of the same column by the following conditions: 1) if the cell (D5) is blank and the cell (A5) is not blank, then fill data into D5 2) if the cell (D5) is blank and the cell (A5) is blank, then no need to fill anything Thanks for in advance. Tlee |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Check the two different cells in the same row
Hi Joel,
Many thanks for your help!!! Tlee It is simplier just to move a into d if a is blank or if a is not blank. sub CheckColumns RowCount = 1 Do while Range("A" & RowCount) < "" if Range("D" & RowCount) = "" then Range("D" & RowCount) = Range("A" & RowCount) end if RowCount = RowCount + 1 loop end sub "tlee" wrote: Hi all, Could anyone tell me how to check all cells of the same column by the following conditions: 1) if the cell (D5) is blank and the cell (A5) is not blank, then fill data into D5 2) if the cell (D5) is blank and the cell (A5) is blank, then no need to fill anything Thanks for in advance. Tlee |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Check the two different cells in the same row
Hi Joel,
Many thanks for your help!!! Tlee It is simplier just to move a into d if a is blank or if a is not blank. sub CheckColumns RowCount = 1 Do while Range("A" & RowCount) < "" if Range("D" & RowCount) = "" then Range("D" & RowCount) = Range("A" & RowCount) end if RowCount = RowCount + 1 loop end sub "tlee" wrote: Hi all, Could anyone tell me how to check all cells of the same column by the following conditions: 1) if the cell (D5) is blank and the cell (A5) is not blank, then fill data into D5 2) if the cell (D5) is blank and the cell (A5) is blank, then no need to fill anything Thanks for in advance. Tlee |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Check 3 cells, only one of the cells my be filled | Excel Worksheet Functions | |||
Check 1 cells value and use the result to change another cells for | Excel Programming | |||
check value into cells | Excel Discussion (Misc queries) | |||
Check cells in a column | Excel Programming | |||
Check Cells are EXACTLY the Same | Excel Programming |