Click here to Skip to main content
15,888,351 members
Home / Discussions / C#
   

C#

 
Questionsorting problem in outlook Pin
john563216-Jul-09 0:11
john563216-Jul-09 0:11 
QuestionC# How to HttpWebRequest through chain/cascade of proxy servers Pin
lermi15-Jul-09 23:55
lermi15-Jul-09 23:55 
Questionhow to drag and drop values from one datagrid to another datagrid? Pin
swetha_insoft15-Jul-09 23:41
swetha_insoft15-Jul-09 23:41 
AnswerRe: how to drag and drop values from one datagrid to another datagrid? Pin
swetha_insoft16-Jul-09 0:14
swetha_insoft16-Jul-09 0:14 
Questioncompression of webcam images [modified] Pin
shekhar25839515-Jul-09 23:08
shekhar25839515-Jul-09 23:08 
AnswerRe: compression of webcam images Pin
Manas Bhardwaj15-Jul-09 23:16
professionalManas Bhardwaj15-Jul-09 23:16 
AnswerRe: compression of webcam images Pin
Christian Graus16-Jul-09 1:30
protectorChristian Graus16-Jul-09 1:30 
QuestionServicePointManager.ServerCertificateValidationCallback Pin
himuskanhere15-Jul-09 21:36
himuskanhere15-Jul-09 21:36 
Dear Friends,

I stuck at a point, to download a file from HTTPS site.

I have a secured web site https/www.mySite.com/.
I havent any idea which Certificate that server is using.
I just want to down load a file from that site.

For that I have written the code:

    private static bool ValidateRemoteCertificate(<br />
         object sender,<br />
         X509Certificate certificate,<br />
         X509Chain chain,<br />
         SslPolicyErrors policyErrors<br />
     )<br />
        {<br />
                   <br />
            if (policyErrors == SslPolicyErrors.None)<br />
               return true;<br />
            else<br />
               return false;<br />
<br />
<br />
));<br />
<br />
     //       // Do not allow this client to communicate with unauthenticated servers.<br />
     //       return false;<br />
     //   }<br />


but it always shows the error "System.Net.Security.SslPolicyErrors.RemoteCertificateNameMismatch"

and if i forcefully return true it works fine...
what is proper solution??????


thnaks in advance
AnswerRe: ServicePointManager.ServerCertificateValidationCallback Pin
jo H20-Jul-09 4:47
jo H20-Jul-09 4:47 
QuestionRecord Not Insert Pin
mjawadkhatri15-Jul-09 21:31
mjawadkhatri15-Jul-09 21:31 
AnswerRe: Record Not Insert Pin
Mycroft Holmes15-Jul-09 22:06
professionalMycroft Holmes15-Jul-09 22:06 
GeneralRe: Record Not Insert Pin
mjawadkhatri15-Jul-09 22:21
mjawadkhatri15-Jul-09 22:21 
GeneralRe: Record Not Insert Pin
K030615-Jul-09 23:01
K030615-Jul-09 23:01 
GeneralRe: Record Not Insert Pin
mjawadkhatri15-Jul-09 23:21
mjawadkhatri15-Jul-09 23:21 
GeneralRe: Record Not Insert Pin
K030615-Jul-09 23:33
K030615-Jul-09 23:33 
AnswerRe: Record Not Insert Pin
Tom Deketelaere15-Jul-09 23:22
professionalTom Deketelaere15-Jul-09 23:22 
AnswerRe: Record Not Insert Pin
Pete O'Hanlon15-Jul-09 23:30
mvePete O'Hanlon15-Jul-09 23:30 
QuestionAccessing Serial Port Remotely Pin
Liya Kebede15-Jul-09 21:16
Liya Kebede15-Jul-09 21:16 
AnswerRe: Accessing Serial Port Remotely Pin
Garth J Lancaster16-Jul-09 0:38
professionalGarth J Lancaster16-Jul-09 0:38 
AnswerRe: Accessing Serial Port Remotely Pin
monstale16-Jul-09 0:52
monstale16-Jul-09 0:52 
GeneralRe: Accessing Serial Port Remotely Pin
Liya Kebede16-Jul-09 2:07
Liya Kebede16-Jul-09 2:07 
GeneralRe: Accessing Serial Port Remotely Pin
monstale16-Jul-09 2:36
monstale16-Jul-09 2:36 
GeneralRe: Accessing Serial Port Remotely Pin
Liya Kebede2-Nov-09 0:47
Liya Kebede2-Nov-09 0:47 
GeneralRe: Accessing Serial Port Remotely Pin
Member 1247082419-Apr-16 5:03
Member 1247082419-Apr-16 5:03 
Questioncall dll on client side Pin
Member 435374515-Jul-09 21:15
Member 435374515-Jul-09 21:15 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.