Found this nugget in the .net247 with a link to the MS site, google didnt list it

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpguide/html/cpconrowstates.asp

In a nutshell :

switch(m_objDataTable.Rows[i].RowState)
{
case DataRowState.Deleted:
this.SettingsManager.RemoveAdminSetting(m_objDataTable.Rows[i][“UserId”,DataRowVersion.Original].ToString());
break;
case DataRowState.Added:
strKey=m_objDataTable.Rows[i][“UserId”].ToString();
strVal=m_objDataTable.Rows[i][“UserName”].ToString();
this.SettingsManager.SetAdminSetting(strKey, strVal);
break;
}

Advertisements