You could, but it won’t taste as good. Canned corn tends to be a bit rubber-like and contains lots of salt. In a pinch, canned corn can work, but generally frozen or freshly removed from the cob works great.