If you want to allow the installation of SolidWorks, simply remove the entries you added to the hosts file.
127.0.0.1 install.solidworks.com 127.0.0.1 www.solidworks.com 127.0.0.1 api.solidworks.com or solidworks host file block install
Add the following lines to your hosts file: If you want to allow the installation of