Depending on what you want to show in your progressBar9
(KB or MB) you could use something like:
progressBar9.Value = (int)(performanceCounter9.NextValue()/1024); //value in MB
textBox5.Text = "Max. memory: " + progressBar9.Value.ToString() + " MB";
or
progressBar9.Value = (int)(performanceCounter9.NextValue()); //value in KB
textBox5.Text = "Max. memory: " + (progressBar9.Value/1024).ToString() + " MB";