marreco
08-02-2012, 04:22 PM
Hi.
I need to have the option to choose the cell with the click of a mouse, and have the result of calculation in the cell where the mouse clicked
Private Sub Worksheet_Calculate()
Soma = 0
Coluna = 1
Do While Cells(Coluna, 1) <> ""
Soma = Soma + Cells(Coluna, 1)
Coluna = Coluna + 1
Loop
Cells(1, 3) = Soma 'Here I would like the return was where I choose in Excel
End SubCross-Post
http://www.excelforum.com/excel-programming-vba-macros/849598-select-the-cell-with-the-click-of-a-mouse-and-have-the-result-of-calculation.html
I need to have the option to choose the cell with the click of a mouse, and have the result of calculation in the cell where the mouse clicked
Private Sub Worksheet_Calculate()
Soma = 0
Coluna = 1
Do While Cells(Coluna, 1) <> ""
Soma = Soma + Cells(Coluna, 1)
Coluna = Coluna + 1
Loop
Cells(1, 3) = Soma 'Here I would like the return was where I choose in Excel
End SubCross-Post
http://www.excelforum.com/excel-programming-vba-macros/849598-select-the-cell-with-the-click-of-a-mouse-and-have-the-result-of-calculation.html