close

Can Conditions include operative actions if true or false? such as:

If cell A7 = quot;Smithquot;, delete row if yes, go to next cell if no ???Jim

No, functions can only return a value, you will need a macro if you want
automated actions

--
HTH
Nick Hodge
Microsoft MVP - Excel
Southampton, England
www.nickhodge.co.uk
HISquot;Jimquot; gt; wrote in message
...
gt; Can Conditions include operative actions if true or false? such as:
gt;
gt; If cell A7 = quot;Smithquot;, delete row if yes, go to next cell if no ???
gt;
Jim,
You need to use VBA to do this.

Deletes any row containing Smith in column A .... must start at last row and
work upwards

Sub DeleteRow()
e.g For r = 100 to 1 step -1
If cells(r,1)=Ucase(quot;Smithquot;) then
cell(r,1).entirerow.delete
End if
Next r
End sub

quot;Jimquot; wrote:

gt; Can Conditions include operative actions if true or false? such as:
gt;
gt; If cell A7 = quot;Smithquot;, delete row if yes, go to next cell if no ???
gt;

arrow
arrow
    全站熱搜
    創作者介紹
    創作者 software 的頭像
    software

    software

    software 發表在 痞客邦 留言(0) 人氣()