Clearing unwanted hex characters with/without regex in c#

I have to clear hex characters from exception message in a better way. For now it works replacing characters manually which seems total disaster like this : var clearedStr = str.Replace(Convert.ToString((char)0x01), "") .Replace(Convert.ToString((char)0x02), "") .Replace(Convert.ToString((char)0x03), "") .Replace(Convert.ToString((char)0x04), "") .Replace(Convert.ToString((char)0x05), "") .Replace(Convert.ToString((char)0x06), "") .Replace(Convert.ToString((char)0x07), "") .Replace(Convert.ToString((char)0x08), "") .Replace(Convert.ToString((char)0x0B), "") .Replace(Convert.ToString((char)0x0C), "") .Replace(Convert.ToString((char)0x0E), "") .Replace(Convert.ToString((char)0x0F), "") .Replace(Convert.ToString((char)0x10), … Read more

Change Visible Month in Calendar

Using .net 4.6.1, I’m doing a calculation on the backend to determine when a customer can select an order date, depending on their weekly invoice day. The calculation is working correctly as is the SelectedDate portion, however, when SelectedDate happens to fall within the following month, my calendar isn’t automatically advancing to show that month by default, it always displays the current month regardless. What am I doing wrong?