How to handle exception in .net
<p>i am trying to handle exception and save that exception in database  </p>

<pre><code>Function1()  
{  
    try  
    {  
        for(int i=0;i&lt;dt.rows.count;i++)  
        {  
            Function2();  
        }  
    }  
    catch(exception ex)  
    {  
        saveInDB(ex.message.tostring(),id);  
    }  

}  

Function2()  
{  
    try  
    {  
        function3()  
    }  
    catch(exception ex)  
    {  
        throw ex;  
    }  
}  

Function3()  
{  
    try  
    {  
        function4()  
    }  
    catch(exception ex)  
    {  
        throw ex;  
    }  
}  

Function4()  
{  
    try  
    {  
        code;  
    }  
    catch(exception ex)  
    {  
        throw ex;  
    }  
}  
</code></pre>

<p>suppose i got a exception in method4 then it will throw it to   function3->Function2->function1 and then function1 will write exception in database.</p>

<p>but   after writing exception in DB i want to continue for loop.</p>

<p>so how should i do?</p>
