I have a 2 computers connected to a switch and a DSL modem. However, I am only getting internet connection in one computer. The other computer is not getting internet connection connection atall. How could I fix this?
Your modem will only hand out one IP address. A switch does not hand out IPs. It only transfers packets to the correct computer.
A router will use that one IP address for itself. It will then hand out its own IPs to what ever networkable components are on the network. The router will enable each component to talk to the other components and let each component access the internet.