Excel provides many built-in functions that meet the requirements of many users. But there are some inadequacies,some problems to use a combination of several built-in functions or nested can be resolved, resulting in the expression is too lengthy,cumbersome,poor readability. To solve the lack of built-in functions, using a custom function is a wise choice. Use a custom function that extends the functionality of Excel functions, but also simplify the user's work,to meet the needs of individual users.