'I'm trying to restrict a cell to specific characters using excel

i'm trying to force the date format of mm/dd/yyyy in a cell in excel using excel for mac v 16.60. the column format must be text.

i'm not great with visual basic, so i'm hoping this is accomplishable via formula or data validation.

i've tried the following: https://answers.microsoft.com/en-us/msoffice/forum/all/forcing-a-particular-format-for-date-data-entry-in/fe2d68c5-12e2-45c5-afb7-a5d1be732bfe

https://www.extendoffice.com/documents/excel/3653-excel-only-allow-date-in-cell.html (#2 under allow only date format in specific cells with data validation function)

is there a way to require 2 digits, a slash, 2 more digits, a slash, then 4 digits in a text-formatted cell?



Solution 1:[1]

There is a Excel formula for text. Place a regular date in cell A2 then in another cell type =TEXT(A2,"mm/dd/yyyy").

If the answer works for you, the expectation is that you checkmark it and upvote it. If the answer does not work for you you add a comment at the bottom and the problem you experience.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Shane S