<p><font size="4">同时选中两个单元格,运行宏则内容互换!</font></p><p><font size="4">Sub ChangVal()<br/>my1value = ActiveCell.Value<br/>For Each a In Selection<br/>If a.Address <> ActiveCell.Address Then<br/>my2value = a.Value<br/>a.Value = my1value<br/>ActiveCell.Value = my2value<br/>End If<br/>Next a<br/>End Sub</font></p><p><font size="4"> </font></p>
[此贴子已经被作者于2007-12-17 23:53:33编辑过] |