Fixing Excel 2003 VBA that appears broken in Excel 2007
I maintain a spreadsheet created by someone else that calls user defined functions.
Recenty I needed to migrate to Office 2007. All worked fine in xl2003, but xl2007 returns #NAME?. Even this simple test fails: Public Function testFunc(MyValue As Variant) As Variant testFunc = "You gave me " & MyValue End Function Can someone give me a hint where to start ? EggHeadCafe - Software Developer Portal of Choice The XML I-Ching: Tao of the DOM http://www.eggheadcafe.com/tutorials...-tao-of-t.aspx |
Fixing Excel 2003 VBA that appears broken in Excel 2007
Did you put the code in a General module (not in a worksheet module, not in the
ThisWorkbook module)? Did you remember to allow macros to run? Jeroen, Boot wrote: I maintain a spreadsheet created by someone else that calls user defined functions. Recenty I needed to migrate to Office 2007. All worked fine in xl2003, but xl2007 returns #NAME?. Even this simple test fails: Public Function testFunc(MyValue As Variant) As Variant testFunc = "You gave me " & MyValue End Function Can someone give me a hint where to start ? EggHeadCafe - Software Developer Portal of Choice The XML I-Ching: Tao of the DOM http://www.eggheadcafe.com/tutorials...-tao-of-t.aspx -- Dave Peterson |
Fixing Excel 2003 VBA that appears broken in Excel 2007
It works for me here when I do this
Sub test() Debug.Print testFunc("value") End Sub What are you passing to it? "Jeroen Boot" wrote: I maintain a spreadsheet created by someone else that calls user defined functions. Recenty I needed to migrate to Office 2007. All worked fine in xl2003, but xl2007 returns #NAME?. Even this simple test fails: Public Function testFunc(MyValue As Variant) As Variant testFunc = "You gave me " & MyValue End Function Can someone give me a hint where to start ? EggHeadCafe - Software Developer Portal of Choice The XML I-Ching: Tao of the DOM http://www.eggheadcafe.com/tutorials...-tao-of-t.aspx . |
All times are GMT +1. The time now is 09:42 AM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com