由于System.Web.Mail只能在frameword1.1中使用,那么1.0怎么发邮件呢?

解决方案 »

  1.   

    Dim mailmsg As New jmail.Message()
            mailmsg.Silent = True
            mailmsg.Charset = "gb2312"        mailmsg.ContentType = "text/plain"
            mailmsg.From = "[email protected]"  '//这里成你的发信人地址
            mailmsg.FromName = "nh-huasen"       '//发信人姓名        '收件人信息
            mailmsg.Subject = Email_Object         '//标题
            mailmsg.AddRecipient(To_Addr)     '//地址//收信人地址
            mailmsg.Body = Email_Body              '//内容//信件内容        '发送邮件参数设置
            mailmsg.MailServerUserName = "[email protected]" '//用户名
            mailmsg.MailServerPassWord = "******"  '//密码        '发送邮件
            If mailmsg.Send("mail.nh-huasen.com") Then
                Return True
            Else
                Return False
            End If