473,699 Members | 2,890 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

About the MX Record Entry of particular hotmail,yahooma il and rediffmail provider

8 New Member
I am designing one web page which checks the existence of the Email Address on the server

For that I have the following code.....this code checks the the existence of gmail address for

e.g xxxx@gmail.com on the Gmail server

so can anyone please tell me what is the MX Record Entry of Hotmail,Yahooma il and Rediffmail provider.

Expand|Select|Wrap|Line Numbers
  1. TcpClient tClient = new TcpClient("gmail-smtp-in.l.google.com", 25);
  2.  
  3.      string CRLF = "\r\n";
  4.      byte[] dataBuffer;
  5.      string ResponseString;
  6.     NetworkStream netStream = tClient.GetStream();
  7.      StreamReader reader = new StreamReader(netStream);
  8.     ResponseString = reader.ReadLine();
  9.     /* Perform HELO to SMTP Server and get Response */
  10.      dataBuffer = BytesFromString("HELO KirtanHere" + CRLF);
  11.      netStream.Write(dataBuffer, 0, dataBuffer.Length);
  12.      ResponseString = reader.ReadLine();
  13.     dataBuffer = BytesFromString("MAIL FROM:<YourGmailIDHere@gmail.com>" + CRLF);
  14.      netStream.Write(dataBuffer, 0, dataBuffer.Length);
  15.      ResponseString = reader.ReadLine();
  16.     /* Read Response of the RCPT TO Message to know from google if it exist or not */
  17.      dataBuffer = BytesFromString("RCPT TO:<"+TextBox1.Text.Trim()+">"+CRLF);
  18.      netStream.Write(dataBuffer, 0, dataBuffer.Length);
  19.     ResponseString = reader.ReadLine();
  20.     if (GetResponseCode(ResponseString) == 550)
  21.     {
  22.         Label1.Visible = true;
  23.         Label1.Text = "Mai Address Does not Exist !";
  24.         Label1.Text = "<font color='red'>Original Error from Smtp Server :</font>" + ResponseString;
  25.         //Response.Write("Mai Address Does not Exist !<br/><br/>");
  26.         //Response.Write("<B><font color='red'>Original Error from Smtp Server :</font></b>" + ResponseString);
  27.     }
  28.     else
  29.     {
  30.         Label1.Visible = true;
  31.         Label1.Text = "exist";
  32.         //Response.Write("valid address");
  33.     }
  34.     /* QUITE CONNECTION */
  35.      dataBuffer = BytesFromString("QUITE" + CRLF);
  36.      netStream.Write(dataBuffer, 0, dataBuffer.Length);
  37.      tClient.Close();
  38.  }
  39.  private byte[] BytesFromString(string str)
  40.  {
  41.      return Encoding.ASCII.GetBytes(str);
  42.  }
  43. private int GetResponseCode(string ResponseString)
  44.  {
  45.      return int.Parse(ResponseString.Substring(0, 3));
  46.  }
Mar 6 '14 #1
0 1326

Sign in to post your reply or Sign up for a free account.

Similar topics

5
3334
by: Ross A. Finlayson | last post by:
Hi, I'm scratching together an Access database. The development box is Office 95, the deployment box Office 2003. So anyways I am griping about forms and global variables. Say for example I'm adding a customer. The Customer fields are mostly foreign keys that refer to primary keys in other tables, left join instead of junction tables at this point. So, when I want to add a customer record, I also need to add records to the other...
1
1998
by: pcnorb | last post by:
I have a form, pulling data from a Products table that has many fields that do lookups to other tables. These are in a one-to-many relationship to a pk in each of said tables. I'd like to be able to compare the data on a BeforeUpdate event to be sure that this data is not duplicated. Here is the structure: Products 8-1 Frames
1
2371
by: ryano | last post by:
Can anyone tell me where to get the code for inserting a record into an access database? I can't find a simple internet site to do this. Thanks in advance, Sean
2
1835
by: =?Utf-8?B?R2Vvcmdl?= | last post by:
Hello everyone, I am implementing a simple C# OLE DB Provider (C# COM Server). For C# (managed code), I am wondering what is the entry point (which coclass and which method), client will invoke at first? It is clear if I write my own client, but I am confused about other clients which I do not have source codes, for example, if I use Microsoft Excel (as a client) to invoke my C# OLE DB Provider, which is the entry point? Any
6
4545
by: teser3 | last post by:
I have my PHP inserting into Oracle 9i. But how do I prevent duplicate record entries? I only have 3 fields in the insert in the action page: CODE <?php $c=OCILogon("scott", "tiger", "orcl"); if ( ! $c ) { echo "Unable to connect: " . var_dump( OCIError() );
6
1945
by: xraive | last post by:
I have two tables Table1(TripEventTypes) TripEventyTypeID EventTypeID Table2(TripEventTypeDetails) TripEventTypeID EventTypeDetailID EventTypeDetailValue I am trying to insert multiple records into table 2 from a form. Is there a way to do this? example would be a form for a Flight event
5
1866
by: KingKen | last post by:
I have a situation whereby I have to enter many records in a db that only have one field that changes. For example software installed on a computer would give you many different rows of data with just a single variant in the software field. I want to know if it is possible to have my form setup in such a way that it takes one instance of constant data and various instances of a variant field but for each variant create a new record and add...
2
2940
by: cambar | last post by:
When Access db is first opened and the first record is entered, tabbing on subform works properly. However, when subsequent records are entered, the subform retains memory of the last field filled in prior record and drops to this field once data is filled in main form. So, if I tab across the main form and expect the first field of the subform to follow, I am disappointed. Cannot figure out how to ensure that after saving a record the tabbing...
1
1523
by: dttin27 | last post by:
I have to create a 2 dimensional array (5X4 (int type)) which can hold 4 exam scores for each of 5 students.Here is my code: #include<stdio.h> int main(void) { int numstu = 5; double studentscore; double score1, score2, score3, score4; int i, z;
0
8705
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9196
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9054
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
8896
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7784
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5879
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4390
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4637
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
3
2015
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.