How to Edit/Update Data in Collection in C#
<p>I have a collection in my C# code</p>

<pre><code>private ObservableCollection&lt;UserForms&gt; _userForms = 
    new ObservableCollection&lt;UserForms&gt;();

public ObservableCollection&lt;UserForms&gt; UserForms { get { return _userForms; } }
</code></pre>

<p>I am filling collection with 4 values</p>

<pre><code>foreach (DataRow dr in DataTable.Rows)
{
                    UserForms.Add(new UserForms()
                    {
                        FormID = Convert.ToInt32(dr["FormID"]),
                        FormName = dr["FormName"].ToString(),
                        FromSyName = dr["FormSyName"].ToString(),
                        Visibility = false,
                        RoleAdd=false,
                        RoleEdit=false,
                        RoleDelete=false
                    });
}
</code></pre>

<p>I am filling this in <code>Form_Load()</code> event</p>

<p>Now I want to update </p>

<pre><code>Visibility = true,
RoleAdd=true,
RoleEdit=true,
RoleDelete=true
</code></pre>

<p>in specified row in the collection.</p>
