To underline the contents you selected, please follow steps below, or if you like using shortcuts, please select the contents first, then press "Ctrl+U":
Step 1: Select the cell or area you need to change;
Step 2: Click the "Home" Tab from Ribbon;
Step 3: Click the command "Underline" in the "Font" area;
Step 4: After the contents you selected are changed.
Step 5: In case you need a different underline style, please select the contents first, then right-click to bring up the dialog box, from the list, click "Format cells";
Step 6: From the "Underline" drop down list, select the style you like.