Super, It is working amazing.. Thanks a lotTry this formula solution of which required Excel 2019 and up.
In E2 array (CSE) formula copied down :
=TEXTJOIN("-",,TEXT(BASE(IFERROR(SMALL(DECIMAL(C2:D2,36),ROW($1:$20)),0),36),"[>]0;"))
View attachment 79826
Hi, It is also working and easy to use also, Thank youPlease try
=IF(C2<D2,C2&"-"&D2,D2&"-"&C2)