using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.IO; namespace 书名总价格计算 { class Program { static void Main(string[] args) { string path = @"C:\Users\Administrator\Desktop\书名总价格计算.txt"; string[] co
商品 数量 单价英语 66 100语文 66 80数学 66 100化学 66 40物理 66 60 上面是文本文档中读入的数据. using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.IO; using System.Diagnostics;//Stopwatch所在命名空间 namespace 书名总价格计算 { class Program { st
Dim fso,f,a set oExcel = CreateObject( "Excel.Application" ) oExcel.Visible = false '4) 打开已存在的工作簿: oExcel.WorkBooks.Open( "F:\1.xlsx" ) On Error Resume Next '判断是否存在Sheet2工作表,不存在新建 If oExcel.WorkSheets("Sheet2") Is Nothing The
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.IO; namespace txtread { class Program { static void Main(string[] args) { // //File 优点:命令简单,可以读各种类型,但是耗内存,因为是以下子全读入内存了 //读 // //Create Delete Copy Move