Englishman John Montagu, the fourth Earl of Sandwich, was a notorious gambler and would spend prodigeous amounts of time at the cards table, even indulging in 24 hour gambling sessions. During one spree, in 1762, Sandwich advised his cook to prepare him a meal that he could eat with one hand, and therefore continue playing his cards with his other hand. No need for a knife or a fork, as forks had started becoming popular by that time. His cook delivered sliced meat inbetween two pieces of toast - and thus the sandwich was created! Or was it?
The 4th Earl of Sandwich frequently travelled to the Eastern Mediterranean, where he would have enjoyed grilled pita breads, small canapes and sandwiches that were traditional in Greek and Turkish cuisine at that time as appetizers. With returning to England, and by actively having sandwiches served to him during gaming, he introduced the idea to other English gentry. So he didn't exactly invent the sandwich, but he did anglicized it, which explains why his title ended up applied to this type of light meal.
Inital usage of sandwiches were for late night drinking parties attended by men, restaurants, and then eventually the food moved to late night balls and similar events towards the end of the 18th century. The convenience and variety that could be created from different combinations made for a real winner that society was ready for, with appearances in cook books - one of the first being author Charlotte Mason.
There is lots more history to explore with sandwiches that we can take a peek at another time!
Sources: Food Timeline