To create a new User Defined Function (UDF), right-click on the UDFs node under the connection node in Server Explorer. From the node's context menu, choose the Create UDF command. This command opens the UDF Editor.
To modify an existing UDF, double-click on the node of the UDF you wish to modify, or right-click on this node and choose the Alter UDF command from the context menu. Either of the commands opens the UDF Editor.
The UDF editor allows you to set the following properties:
So-name (DLL name)
There are text fields for both names, a combo box for the return type, and a check box to indicate if the UDF is aggregate. All these options are also accessible via the Properties window.
Server in the Properties window is
To save changes you have made, use either Save or Save All buttons of the Visual Studio main toolbar, or just press Ctrl+S. Before changes are saved, you will be asked to confirm the execution of the corresponding SQL query in a confirmation dialog.