ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   button to update cell (https://www.excelbanter.com/excel-programming/286198-button-update-cell.html)

Jerett

button to update cell
 
I am trying to assign an option button to perform a calculation on the contents of a cell say C12. Then replace the contents of the Cell with the product of the equation. It seems like it should be as easy as assigning a variable1 to = C12, perform calculation on variable ((variable1*D12)+E12), populate C12 with variable2. But, I cant seem to get the code right
Any Help would be appreciated


Bob Phillips[_6_]

button to update cell
 
Jerrett,

Is it not as simple as?

Range("C12").Value = (Range("C12").Value * _
Range("D12").Value ) + _
Range("E12").Value

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)

"Jerett" wrote in message
...
I am trying to assign an option button to perform a calculation on the

contents of a cell say C12. Then replace the contents of the Cell with the
product of the equation. It seems like it should be as easy as assigning a
variable1 to = C12, perform calculation on variable ((variable1*D12)+E12),
populate C12 with variable2. But, I can't seem to get the code right.
Any Help would be appreciated.




Jerett

button to update cell
 
you are right. I was trying to make it much more
complicated than it is. Thank you.
-----Original Message-----
Jerrett,

Is it not as simple as?

Range("C12").Value = (Range("C12").Value * _
Range

("D12").Value ) + _
Range

("E12").Value

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)

"Jerett" wrote in

message
news:F6CF7200-EEBB-4B2D-A920-

...
I am trying to assign an option button to perform a

calculation on the
contents of a cell say C12. Then replace the contents

of the Cell with the
product of the equation. It seems like it should be as

easy as assigning a
variable1 to = C12, perform calculation on variable

((variable1*D12)+E12),
populate C12 with variable2. But, I can't seem to get

the code right.
Any Help would be appreciated.



.



All times are GMT +1. The time now is 11:56 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com