• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Unable to use UDF from personal macro workbook to all workbooks

Bhawani

Member
Hi All,

I have created some UDF with for my day to day task and kept them in personal macro workbook which is hidden and opens every time in back-end whenever i use excel.

UDF is kept in module and start like this :
Code:
Public Function Vlookup_Conditional
'macro goes here
End Function

but i am unable to use it another workbook unable to understand where i am wrong

Thanks & Regards,
 
Hi Bhawani ,

What happens if you use it in your other workbook , as follows ?

=Vlookup_Conditional()

Given the name of your UDF , I would have thought it would have parameters , since a lookup function should have as parameters the value to be looked up , the range over which the lookup is to be done , the value to be returned ; 3 parameters at the least.

Narayan
 
Ok It seems to be go lengthy however i have too ....

@ Narayan Sir - Sir not getting UDF even in my other workbook functions list.

@ Deepak - how could i check those thing please tell.
 
Hi Bhawani ,

You have not answered the question ; what happens if you put in the following formula ?

=Vlookup_Conditional()

Narayan
 
Run this & share the worksheet snap.

Code:
Option Explicit

Sub MyVersions()
    [A1] = Application.OperatingSystem
    [A2] = Application.Version
End Sub
 
You can:
-Keep it in your PMB
-Save it as an addin (I like this one better)

If you need to share it, you can just share the addin or bake it into the workbook.
 
Hi Dan_l

Its already in PMB
But not getting in function list

How could i save it as a Add-in
 

Attachments

  • Vlookup Conditional Snap Shot.jpg
    Vlookup Conditional Snap Shot.jpg
    45.8 KB · Views: 3
Run this & share the worksheet snap.

Code:
Option Explicit

Sub MyVersions()
    [A1] = Application.OperatingSystem
    [A2] = Application.Version
End Sub

Deepak....Just a thought....Don't you think knowing OS /Office version is much easier than creating a code like this?

Regards,
 
.........Snap is attached.......

its very strange [A1] or [A2] doesnt require any sheet name. wow...

You have Win 7 32 bit with ms office 2010.
Sheet name is not required as by default it will be activesheet.

You need to write PERSONAL.XLSB!Vlookup_Conditional to get it work on other workbooks.
You have to prefix the formula with PERSONAL.XSLB! so that xl could loop behind the scene.
 
Back
Top