Select the table to be made with the mouse, right-click, select "Cell Format", select the "Border" button, and then select the required line type. Before Excel makes tables, you should set the margins and paper size in the page setup. Because the working interface of Excel is relatively large, if it is not set, it will exceed the paper size you set.
Only on behalf of personal views, don't spray if you don't like it, thank you.