No. Back in the Golden Age of cruising it was common for everyone to dress for dinner. These days, many people want a more casual vacation. During your cruise there will usually be one or more formal nights (depending on how long the cruise is). It is an invitation for folks who want to have an opportunity to really put on their finest to do so. At least one of the nights will coincide with the photo department offering sittings for studio style photos…at a price, of course. Attire for the formal nights should be at least business type attire but can go up to the smartest tuxedos and formal gowns.
Now, that doesn’t mean that anything goes either. The dining rooms do have a minimum dress code; particularly at dinner time. Bathing suits and pajamas are not appropriate attire. Shorts and sandals are fine for breakfast and lunch but not for dinner. Just think about how you’d dress to go out to a nice restaurant rather than McDonald’s and act accordingly.