• 大小: 0.44M
    文件类型: .zip
    金币: 1
    下载: 0 次
    发布日期: 2021-02-24
  • 语言: C#
  • 标签:

资源简介


资源截图

代码片段和文件信息

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using Microsoft.Office.Interop.Excel;

namespace CreateExcel
{
    public partial class Frm_Main : Form
    {
        public Frm_Main()
        {
            InitializeComponent();
        }

        private void btn_Select_Click(object sender EventArgs e)
        {
            if (folderBrowserDialog1.ShowDialog() == DialogResult.OK)//判断是否选择了路径
            {
                txt_Path.Text = folderBrowserDialog1.SelectedPath;//显示选择的路径
            }
        }

        private void btn_Create_Click(object sender EventArgs e)
        {
            string P_str_path = txt_Path.Text;//记录路径
            Microsoft.Office.Interop.Excel.Application excel = new Microsoft.Office.Interop.Excel.Application();//实例化Excel对象
            Microsoft.Office.Interop.Excel.Workbook newWorkBook = e

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     文件         923  2010-06-03 19:43  CreateExcel\CreateExcel.sln
     文件       19968  2010-11-03 15:41  CreateExcel\CreateExcel.suo
     文件        5172  2010-11-03 15:40  CreateExcel\CreateExcel\CreateExcel.csproj
     文件        2063  2010-06-08 09:23  CreateExcel\CreateExcel\Frm_Main.cs
     文件        4779  2010-06-03 19:54  CreateExcel\CreateExcel\Frm_Main.Designer.cs
     文件        6022  2010-06-03 19:54  CreateExcel\CreateExcel\Frm_Main.resx
     文件         495  2010-06-03 19:47  CreateExcel\CreateExcel\Program.cs
     文件       10240  2010-11-03 15:40  CreateExcel\CreateExcel\bin\Debug\CreateExcel.exe
     文件       24064  2010-11-03 15:40  CreateExcel\CreateExcel\bin\Debug\CreateExcel.pdb
     文件       14328  2010-06-03 19:43  CreateExcel\CreateExcel\bin\Debug\CreateExcel.vshost.exe
     文件         490  2009-06-11 05:14  CreateExcel\CreateExcel\bin\Debug\CreateExcel.vshost.exe.manifest
     文件      155648  2010-11-03 15:40  CreateExcel\CreateExcel\bin\Debug\Interop.Office.dll
     文件     1100392  2007-10-10 09:48  CreateExcel\CreateExcel\bin\Debug\Microsoft.Office.Interop.Excel.dll
     文件        3208  2010-11-03 15:40  CreateExcel\CreateExcel\obj\Debug\CreateExcel.csproj.FileListAbsolute.txt
     文件         850  2010-11-03 15:40  CreateExcel\CreateExcel\obj\Debug\CreateExcel.csproj.GenerateResource.Cache
     文件         796  2010-11-03 15:40  CreateExcel\CreateExcel\obj\Debug\CreateExcel.csproj.ResolveComReference.cache
     文件       10240  2010-11-03 15:40  CreateExcel\CreateExcel\obj\Debug\CreateExcel.exe
     文件         180  2010-11-03 15:40  CreateExcel\CreateExcel\obj\Debug\CreateExcel.Frm_Main.resources
     文件       24064  2010-11-03 15:40  CreateExcel\CreateExcel\obj\Debug\CreateExcel.pdb
     文件         180  2010-11-03 15:40  CreateExcel\CreateExcel\obj\Debug\CreateExcel.Properties.Resources.resources
     文件      155648  2010-11-03 15:40  CreateExcel\CreateExcel\obj\Debug\Interop.Office.dll
     文件        8724  2010-11-03 15:40  CreateExcel\CreateExcel\obj\Debug\ResolveAssemblyReference.cache
     文件        1354  2010-06-03 19:43  CreateExcel\CreateExcel\Properties\AssemblyInfo.cs
     文件        2872  2010-06-03 19:43  CreateExcel\CreateExcel\Properties\Resources.Designer.cs
     文件        5612  2010-06-03 19:43  CreateExcel\CreateExcel\Properties\Resources.resx
     文件        1096  2010-06-03 19:43  CreateExcel\CreateExcel\Properties\Settings.Designer.cs
     文件         249  2010-06-03 19:43  CreateExcel\CreateExcel\Properties\Settings.settings

评论

共有 条评论