creating user defined function link