function createEmail() { // Create a new message and fill all its fields var iMsg =new ActiveXObject("CDO.Message"); iMsg.To ="ee@tt.com"; iMsg.From ="aa@tt.com"; iMsg.Subject ="test subject"; iMsg.TextBody ="test body"; // Set SMTP server iMsg.Configuration.Fields("http://schemas.microsoft.com/cdo/configuration/smtpserver") ="192.168.68.1"; // Use the SMTP over the netowrk for sending method iMsg.Configuration.Fields("http://schemas.microsoft.com/cdo/configuration/sendusing") =2; // Make persistent iMsg.Configuration.Fields.Update(); // Send the message iMsg.Send(); }