Dim basicAuthentication As System.Net.NetworkCredential = New System.Net.NetworkCredential("userid@gmail.com", "password")
sc1.EnableSsl = True
sc1.UseDefaultCredentials = False
sc1.Credentials = basicAuthentication
Add the above code in your application. Note the code is in VB. convert it into C#.