3
Answers

how to access gridview another form data?

chinna

chinna

12y
1.8k
1
hi friends,
         i am getting data from database by using gridview in one form (name as main.cs.). i want to update data to database. so i created another form (name as update.cs) to view selected row... how can i use gridview data  from update.cs form..


Thanks ,
Answers (3)
0
Vasanth
NA 2.3k 309.6k 15y


Just simply resolve by ,


After the email is sent use Dispose() method of MailMessage. So here its release all resources and others are disposed here.


And also you can create MailMessage within using block. As a result all resources will be released (disposed or closed) automatically when execution of the block completes.
 


using(MailMessage mmEmail = new MailMessage(...))
{
}

I specially like the alternative solution for "USING". and its very popular in the programming end.

Please mark as answer , if it helps you.