Hi Chuhua,
1. In CW 10.7, we can create library with wizard, just select "library" for project type.

2. after creating the lib project, write your functions in source code and also declare it in header file (.h)
3. copy the generated .lib and .h to user project folder.
4. add the lib path to user project "properties", "settings", "DSC Linker", "input", "Additional Libraries"
Please follow above steps and see how it works.
Have a great day,
Jennie Zhang
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------