摘要: 1 private void insertIntoMes(string dayTime, string strNYCode, string strNYName, string strActWT, string strComName, string strNote) 2 { 3 string connectionString = ConfigurationManager.ConnectionStrings["AppDBServer"].ConnectionString; 4 OracleConnection con = new OracleConnect... 阅读全文
posted @ 2011-11-23 14:45 魔都_XL 阅读(408) 评论(0) 推荐(0) 编辑
摘要: 新建个config文件<?xml version="1.0" encoding="utf-8"?><!-- 注意: 除了手动编辑此文件以外,您还可以使用 Web 管理工具来 配置应用程序的设置。 可以使用 Visual Studio 中的“网站”->“Asp.Net 配置”选项。 设置和注释的完整列表在 machine.config.comments 中, 该文件通常位于 \Windows\Microsoft.Net\Framework\v2.x\Config 中--><configuration> <ap 阅读全文
posted @ 2011-11-23 14:38 魔都_XL 阅读(246) 评论(0) 推荐(0) 编辑
摘要: 1 private void OpenExcel(string strExcelName,string strTempletPath, string dayTime) 2 { 3 ExcelApplication exc = new ExcelApplication(); 4 exc.DisplayAlerts = false; 5 exc.EnableEvents = false; 6 DirectoryInfo dir = new DirectoryInfo(ReportPathDispatch); 7 ... 阅读全文
posted @ 2011-11-23 11:02 魔都_XL 阅读(240) 评论(0) 推荐(0) 编辑
摘要: DirectoryInfo dir = new DirectoryInfo(ReportPathDispatch);foreach (FileInfo fi in dir.GetFiles("*.xls")){ if (fi.Name == strExcelName) { // 这个 fi 就是你要的 xls 文件 }}ReportPathDispatch是文件的物理路径例如:D:\ems\EMSReport\Report\调度报表,这个文件夹下面的内容; 阅读全文
posted @ 2011-11-23 10:53 魔都_XL 阅读(718) 评论(0) 推荐(0) 编辑