>> Unfortunately, the company loses one person who could afford the company's product and replaces that person with many who can't. >>
Wrong again. Indians now can buy more printers and computers because they receive higher wages AND because printers and computers cost less.
Loss of jobs to Indians also creates other opportunities downstream: you need more interpreters who know Indian languages, you need managers to oversee Indians, US programmers are free to do more creative work than primitive run-of-the-mill coding outsourced to Indians, etc. I can't predict all the opportunities, nobody can.
Luddites used to destroy machines in the 18th centuries, thinking that all jobs would soon disappear. Could they imagine railroads, airplanes, oil business, the automobile, the computer, etc, etc?
Of course not. Most protectionists and labor unions refuse to think. All they want is one job for life and iron-clad job security.