I want to convert the following code from C# forms To C# wpf
string MSMS_Number ,MMessage ;
for ( i = 0; i < dataGrid1.Items.Count - 1; i++)
{
MSMS_Number = dataGrid1.Columns..ToString();
MMessage = dataGrid1.Items[i].ToString();
MessageBox.Show(MSMS_Number.ToString());
MessageBox.Show(MMessage.ToString());
}