zoukankan      html  css  js  c++  java
  • 获取html

    //获取模板
                                    string fileName = "E:\\MailSend\\MailSend\\MailSend\\MailTemplete\\MailSkyTypeTemplet.htm";
                                    FileStream aFile;
                                    try
                                    {
                                        aFile = new FileStream(fileName, FileMode.Open, FileAccess.Read);
                                    }
                                    catch
                                    {
                                        return;
                                    }
                                    StreamReader sr = new StreamReader(aFile, Encoding.UTF8);

                                    string templet = sr.ReadToEnd();
                                    sr.Close();
                                    #endregion
                                    #region get templet

                                    //获取模板
                                    string fileNamebox = "E:\\MailSend\\MailSend\\MailSend\\MailTemplete\\MessageBoxTemplet.htm";
                                    //FileStream aFilebox;
                                    try
                                    {
                                        aFile = new FileStream(fileNamebox, FileMode.Open, FileAccess.Read);
                                    }
                                    catch
                                    {
                                        return;
                                    }
                                    sr = new StreamReader(aFile, Encoding.UTF8);

                                    string templetbox = sr.ReadToEnd();
                                    sr.Close();
                                    #endregion
                                    string body = GetString(templet, "_beginHead", "_endFoot", "");
                                    string bodybox = GetString(templetbox, "_beginHead", "_endFoot", "");

  • 相关阅读:
    使用Eclipse调试Java程序的10个技巧
    向mysql中插入格式为"yyyyMMdd HH:mm:ss"的时间
    乐观锁和悲观锁
    js验证表单大全
    subclipse版本回滚功能
    (转)Linux(RedHat AS4)下架设subversion(svn)服务器
    Redhat5下安装Apache2与Subversion1.6.15
    (转)深入探讨 Java 类加载器
    (转)Java深度历险(一)——Java字节代码的操纵
    关于SVN 目录结构
  • 原文地址:https://www.cnblogs.com/tianxiang2046/p/2480582.html
Copyright © 2011-2022 走看看