For the following Enum:
public enum ContentKey {
Menu = 0,
Article = 1,
FavoritesList = 2
};
The enum ContentKey returns an integer 0,1,2. How can I convert or cast this so that it returns a two digit zero padded string “00”, “01” .. “99” etc
When you call
ToStringyou can use the format string"00"to ensure that you get at least two digits: