ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   vba excel - public function in module (https://www.excelbanter.com/excel-programming/401877-vba-excel-public-function-module.html)

[email protected]

vba excel - public function in module
 
i created a public function in a module. when i call it in excel, it
works fine. but as soon as i open any other workbook (even a new one),
it returns a value error. i have to go back into that cell and hit
enter for it to work again.

thoughts?

thanks,
sg

Gaurav Kothari

vba excel - public function in module
 

In order to use function globaly to other workbook, you had to make
Addin......

Follow this :
- Create new Excel file
- Write your code(function)
- Save file as Excel Add-in (.xla file).
.....now, Go to Tools -- Addins... and load the saved file.

now this The function will now be globally available to all.

will not work if moved to a different machine, as it a different case.......:)

Gaurav Kothari


" wrote:

i created a public function in a module. when i call it in excel, it
works fine. but as soon as i open any other workbook (even a new one),
it returns a value error. i have to go back into that cell and hit
enter for it to work again.

thoughts?

thanks,
sg



All times are GMT +1. The time now is 09:41 PM.

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