Hello
I want to get unread mail count in VC++. I have done it in C#.Net with following code -
Collection<UnreadMails> GetNewMails()
{
WebRequest webGmailRequest = WebRequest.Create(@"https://mail.google.com/mail/feed/atom");
webGmailRequest.PreAuthenticate = true;

NetworkCredential loginCredentials = new NetworkCredential(txtUserName.Text.Trim(), txtUserPassword.Text.Trim());
webGmailRequest.Credentials = loginCredentials;

WebResponse webGmailResponse = webGmailRequest.GetResponse();
Stream strmUnreadMailInfo = webGmailResponse.GetResponseStream();

StringBuilder sbUnreadMailInfo = new StringBuilder(); byte[] buffer = new byte[8192]; int byteCount = 0;

while ((byteCount = strmUnreadMailInfo.Read(buffer, 0, buffer.Length)) > 0)
sbUnreadMailInfo.Append(System.Text.Encoding.ASCII.GetString(buffer, 0, byteCount));

XmlDocument UnreadMailXmlDoc = new XmlDocument();
UnreadMailXmlDoc.LoadXml(sbUnreadMailInfo.ToString());
XmlNodeList UnreadMailEntries = UnreadMailXmlDoc.GetElementsByTagName("entry");
}
So by using url "https://mail.google.com/mail/feed/atom" and provide login credential, i am able to get a XML file which contain unread mail information.

The same i want to do in VC++.
Can anybody help me????