how do I use a excel function inside the vba editor -


I want to type an excel function like this. Dec2BinEx = dec2bin (x) + 10 termination function

Public function Dec2BinEx (as long as X)

This is an extension of the Dec2Bin function. An error is occurring while attempting to use. How do I call the excel function inside the Visual Basic Editor?

In general, you can assign Excel functions to Application.WorksheetFunction.SomeFunctionName . However, Dec2Bin is special, because it is an add-in function, and does not have a pure Excel function. Therefore, the application. The worksheet function does not work here . Instead, you have to make the add-in work available for your code. To do this, follow these steps

  • In Excel, menu tools / add-ins, make sure the add-in analysis toolpack - VBA Is imported.

  • Then, set a reference to this add-in in your code: In the VBA editor, menu tool / reference, atpvbaen.xls .

Then, your original code, as it has been posted in your XCiston, should work fine.


Comments

Popular posts from this blog

sql - dynamically varied number of conditions in the 'where' statement using LINQ -

asp.net mvc - Dynamically Generated Ajax.BeginForm -

Debug on symbian -