I would like to clear values in select cells by pushing a quot;Reset Valuesquot;
button. How can I make one? Thanks for any help on this.

Here's a simple example ..

Sample construct at:
www.savefile.com/files/3858780
ResetMultiCellRange_1vagrowr_misc.xls

Draw a Command Button from the Control Toolbox* toolbar on the sheet
*Activate it if necessary, via clicking: View gt; Toolbars gt; Control Toolbox

Right-click on the button gt; View Code
Copy gt; paste the code below into the code window on the right
(clear the defaults first)

Private Sub CommandButton1_Click()
Range(quot;B2,B4,B6,D2,D4,D6quot;).ClearContents
End Sub

Press Alt Q to exit VBE and return to Excel

Click the quot;Exit Design Modequot; icon** on the Control Toolbox Toolbar
**the one with the quot;trianglequot; pic

Test it out. Clicking the button will clear the multi-cell range:
B2,B4,B6,D2,D4,D6

--
Rgds
Max
xl 97
---
Singapore, GMT 8
xdemechanik
savefile.com/projects/236895
--
quot;1vagrowrquot; gt; wrote in message
...
gt; I would like to clear values in select cells by pushing a quot;Reset Valuesquot;
gt; button. How can I make one? Thanks for any help on this.
文章標籤
全站熱搜
創作者介紹
創作者 software 的頭像
software

software

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