Restrict selection

I would like to set a maximum for a selection. Example: I have a selection of 6 pieces, but can only select a maximum of 3. Is that possible? And if so, how?
Thank you very much

Replies are visible only to logged in members with an active subscription.