The people of region of current day Pakistan accepted Islam after the advent of Mohammed - bin -Quasim
Not only that, Punjab became a muslim majority only in the 1900s according the 1881 census it had 47% muslims but the last census in 1941 under the British gave 53% as Muslims. So the conversion of people to Islam took place over more than a 1000 years very gradually rather than in a quick shot mass conversion.
http://www.global.ucsb.edu/punjab/journal_11_1/6_krishan.pdf