View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 27,285
Default command button to calculate two cell values?

Private Sub CommandButton1_Click()
Range("D10").Value = Range("D8").Value + _
Range("D9").Value
End Sub

--
Regards,
Tom Ogilvy


"sunil5" wrote in
message ...

Hi,

Probably an easy one for most...

I've got a command button and I would like it so when I press it, it
calculates the values in cells "D8" and "D9" and puts the total in
"D10"


Any help would be much appreciated.

Thanks.


--
sunil5
------------------------------------------------------------------------
sunil5's Profile:

http://www.excelforum.com/member.php...o&userid=13614
View this thread: http://www.excelforum.com/showthread...hreadid=382482