If I have a string variable with value as follows :-
string mystring = "TYPE1, TYPE1, TYPE2, TYPE2, TYPE3, TYPE3, TYPE4, TYPE4";
and I want to manipulate this string and make it as follows:-
string mystring = "TYPE1,TYPE2,TYPE3,TYPE4";
ie I want to just remove all the duplicates in it, how should I do it?
Please help. Thanks.
You can do the following: