编写邮件程序时,无法显示主题, 我写的邮件程序,对方收到之后不显示主题,不知道在SMTP或者其他的邮件协议中有没有关于邮件主题的命令啊,求各位前辈赐教,晚辈先谢过了 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 public void sendMessage(String addressTo,String mailText){ try{ System.out.println(receive()); String hostName = InetAddress.getLocalHost().getHostName(); out.println("EHLO " + hostName); String ehlo ; do{ ehlo = receive(); System.out.println(ehlo); } while(!ehlo.equals("250 8BITMIME")); out.println("AUTH LOGIN"); System.out.println(receive()); out.println(EncodeBase.enCode(new UserInfo().getUserName().getBytes())); System.out.println(receive()); out.println(EncodeBase.enCode(new UserInfo().getUserPass().getBytes())); System.out.println(receive()); out.println("Mail From:<" + new UserInfo().getUserAddress() + ">"); System.out.println(receive()); out.println("Rcpt To:<" + addressTo + ">"); System.out.println(receive()); out.println("Data"); System.out.println(receive()); out.println(mailText); out.println("."); System.out.println(receive()); out.println("Quit"); System.out.println(receive()); }catch(Exception e){ System.out.println("发送消息出错了"); } } Java上机实现统计某一目录下每个文件中出现的字母个数、数字个数、空格个数及行数? delphi系统,现在要用java扩展功能 怎么快速读取这钟字符串一次两个"str1/str2/str3.." 高手进,高分请高手!!!!! (String) 四则运算公式的分析 String类保存中文问题 很考人哦! 一个小问题想问问各位高手!! 谁在用JBuilder开发Applet,能不能告诉我你倒底是怎么让IE显示出Applet的 java下拉菜单显示对象名 昨天答辩顺利通过了,攒人品,散分。 .....如何更新界面的JLabel的颜色?......
try{
System.out.println(receive());
String hostName = InetAddress.getLocalHost().getHostName();
out.println("EHLO " + hostName);
String ehlo ;
do{
ehlo = receive();
System.out.println(ehlo);
}
while(!ehlo.equals("250 8BITMIME"));
out.println("AUTH LOGIN");
System.out.println(receive());
out.println(EncodeBase.enCode(new UserInfo().getUserName().getBytes()));
System.out.println(receive());
out.println(EncodeBase.enCode(new UserInfo().getUserPass().getBytes()));
System.out.println(receive());
out.println("Mail From:<" + new UserInfo().getUserAddress() + ">");
System.out.println(receive());
out.println("Rcpt To:<" + addressTo + ">");
System.out.println(receive());
out.println("Data");
System.out.println(receive());
out.println(mailText);
out.println(".");
System.out.println(receive());
out.println("Quit");
System.out.println(receive());
}catch(Exception e){
System.out.println("发送消息出错了");
}
}