User defined function in different workbooks/addins problem

winxpdows

New Member
Joined
Apr 21, 2011
Messages
24
Hi Everyone,

Could use any help on this problem I'm having.

I created an addin that puts a formula in a cell to make use of a UDF in the addin. It works fine.

But when I make changes to my addin, save it as new name, load the new addin (same as the old but with new code for other things) and then open the workbook that had the UDF working, it now changes from

=customUDFfunction(1,2,3)

to

='C:\Documents and Settings\homeuser\Application Data\Microsoft\AddIns\AddinV123.xla'!customUDFfunction(1,2,3)


the code I'm using to create the formula in the cell is

Code:
Cells(x, y).Formula = "=customUDFfunction(1,2,3)"


I've looked around and can't find anything. I'm assuming that when I create the formula in the cell it gets tagged somehow with the addin name and location. Any ideas how to just put the formula with keeping it specific to the addin that created it?

Thanks in advance for ANY ideas!
 

Excel Facts

How can you automate Excel?
Press Alt+F11 from Windows Excel to open the Visual Basic for Applications (VBA) editor.
Just a shot in the dark, have you tried using? Don't know if it will work, but it's worth trying!

Code:
Cells(x, y).FormulaR1C1 = "=customUDFfunction(1,2,3)"
 
Upvote 0

Forum statistics

Threads
1,214,985
Messages
6,122,606
Members
449,089
Latest member
Motoracer88

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top