Hi,
You may try this approach. In cell H13, enter "Entries" (without quotes) and in cell I13, enter "frequency of entry per row" (without quotes). In H14:H20, enter X/Y,X/Z,a,b,c,y,z. In I14:I20, enter 2,2,1,1,1,1,1. Click on cell A4 and go to Data > Validation > List. In the Sourece box, enter =$H$14:$H$20. Copy this to the right (till where a user woudl be allowed to enter data). Now click on cell B4 and go to Home > Styles > Conditional formatting > New Rule > Use a formula to determine which cells to format. In the while box, which appears there, enter the following formula
=(OR(AND(ISNUMBER(SEARCH("/",B4)),SUMPRODUCT(1*(ISNUMBER(SEARCH("/",$A4:A4))))=0,COUNTIF($A4:B4,B4)<=VLOOKUP(B4,$H$14:$I$20,2,0)),AND(ISNUMBER(SEARCH("/",B4)),SUMPRODUCT(1*(ISNUMBER(SEARCH("/",$A4:A4))))=1,COUNTIF($A4:B4,B4)<=VLOOKUP(B4,$H$14:$I$20,2,0),COUNTIF($A4:A4,B4)=1),AND(ISERROR(SEARCH("/",B4)),(COUNTIF($A4:B4,B4)<=VLOOKUP(B4,$H$14:$I$20,2,0)))))=FALSE
Apply the format as Red font (or whatever you wish). Entries which do not specify the data entry rule will get coloured in red
If you are wondering why i have not entered this formula in Data > Validation > All > Custom, the reason is the length of thr formula. There is a limitation on the length of a formula which one can write in Data Validation.
Please keep in mind that you must enter data in in continuous cells from left to right i.e. enter data in A4, B4, C4, D4 etc. Do not enter data in A4, D4, B4 etc.
Hope this helps. Do let me know how this works.