ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   re-execute vba function (https://www.excelbanter.com/excel-programming/363389-re-execute-vba-function.html)

Nader

re-execute vba function
 
Hello,



I have create a function in excel using vba and I would like to refresh that
function without going in each cell and press enter. Is there a way to do
that programmatically?



Thanks in advance.



Nader



colofnature[_45_]

re-execute vba function
 

You could either make your function volatile by adding

Application.Volatile

to it's code, thus making it recalculate when any other function does,
or use the Calculate method of the Workbook, Worksheet or Range in
which your function appears, e.g.

Application.Calculate


Col


--
colofnature
------------------------------------------------------------------------
colofnature's Profile: http://www.excelforum.com/member.php...o&userid=34356
View this thread: http://www.excelforum.com/showthread...hreadid=548894


Nader

re-execute vba function
 
Thanks a lot Col. It's working prefectly.

Nader

"colofnature" a
écrit dans le message de news:
...

You could either make your function volatile by adding

Application.Volatile

to it's code, thus making it recalculate when any other function does,
or use the Calculate method of the Workbook, Worksheet or Range in
which your function appears, e.g.

Application.Calculate


Col


--
colofnature
------------------------------------------------------------------------
colofnature's Profile:
http://www.excelforum.com/member.php...o&userid=34356
View this thread: http://www.excelforum.com/showthread...hreadid=548894




Nader

re-execute vba function
 
thanks a lot !
"colofnature" a
écrit dans le message de news:
...

You could either make your function volatile by adding

Application.Volatile

to it's code, thus making it recalculate when any other function does,
or use the Calculate method of the Workbook, Worksheet or Range in
which your function appears, e.g.

Application.Calculate


Col


--
colofnature
------------------------------------------------------------------------
colofnature's Profile:
http://www.excelforum.com/member.php...o&userid=34356
View this thread: http://www.excelforum.com/showthread...hreadid=548894





All times are GMT +1. The time now is 01:43 PM.

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