Forum

How to convert a Le...
 
Notifications
Clear all

How to convert a Lengthy if Function into User Define Function (UDF)

2 Posts
2 Users
0 Reactions
144 Views
(@Anonymous)
Posts: 0
New Member Guest
 

How to convert any lengthy formula in User Define Function (UDF)

For eg:

=IF(OR(E2="",H2=""),"",(NETWORKDAYS(E2,H2)-1)*"9:30")

 

Thanks in advacne.

 
Posted : 02/08/2016 4:47 am
Philip Treacy
(@philipt)
Posts: 1632
Member Admin
 

Hi Pramod,

A UDF is specific to whatever task you are trying to do, so I can't give instructions on how to write one for 'any lengthy formula'.

I would also say that if you already have a working formula then I don't see any point in rewriting it as a UDF.  Your UDF would still have to do the same calculations and deal with the same parameters/data.

UDF's are better suited to doing something that isn't already a function in Excel e.g.

Converting Numbers to Words

Creating Bar Codes

Regards

Phil

 
Posted : 02/08/2016 9:21 pm
Share: