When adding string to Hashtable, string gains unrecognizable characters : <p>So currently I have a hash table that I create and populate it with keys and values</p>

<pre><code>Hashtable m_hash = new Hashtable();
</code></pre>

<p>I then have a string that I have created with a value that will replace a specific value in the hash table.</p>

<pre><code>string birthday = "1979/01/01"
</code></pre>

<p>I then remove the existing value from the hash table and we add in our new value into the hash table.</p>

<pre><code>//0x00080023 is the key in the hash table
m_hash.Remove(0x00080023);
//Then we add in the new value into the key location
m_hash.Add(0x00080023, birthday);
</code></pre>

<p>After we write the hash table to the file. However, when you open up the file the result is as follows:</p>

<p><a href="https://i.stack.imgur.com/VwYkn.png" rel="nofollow noreferrer">Results of our program</a></p>

<p>As you can see at the end of the string there are some unrecognizable characters in the string. Could this be because of the way that we are adding the string into the hash table? Should the string be formatted in a specific way? (Currently it's formatted normally as UTF 16) Any help is appreciated. </p>
