使用C#学习Office文件的处理(pptx docx xlsx)

news2024/10/27 12:39:37

Office文件 是指PPT 、word、Excel 这些常用工具生成的文件 ,例如 pptx docx xlsx。

这些文件的读取和生成有很多很多库 例如 NOPI 、DevExpress、C1、Aspose、Teleric 等等,各有各的优缺点。俺今天不讲这个,俺只是讲讲如何了解Office文件的格式。

说起Office文件,就绕不开微软,说起微软的Office文件 就不得不提及

这是微软给的Office的SDK,在对一些复杂文件的处理上特别有用,俺有一次处理一批复杂的文档,这批文档里有大量的数学公式,例如

 ,

这个公式,文档中存储的是数据流不是图片,俺用了很多第三方的都不行(DevExpress 应该可以,但是要购买贵的那个版本,俺看到版本说明里有支持,但是俺之前买的版本不是这个),所以用了微软的DocumentFormat.OpenXml.dll。

Open XML SDK 有2个很强大的功能,一个是结构化解析文档,另一个是逆向出C#源码

先看一个例子:

然后用Open XML SDK 打开这个文件

左边是文档结构,右边就是逆向出的C#代码。也是一种反编译了。

在VS里执行右边的代码就可以生成出完全一样的Office文件。

ppt word 文件也可以同样处理。

俺前面说的读那个公式,也是用这个SDK 逆向了一下文件,然后就知道如何提取那些特殊数据了。

如果对这个逆向工具感兴趣,还可以直接到微软去下载这个SDK的源码,这个逆向,微软提供了源码。

另 

 private void GenerateWorksheetPart12Content(WorksheetPart worksheetPart12)
        {
            Worksheet worksheet12 = new Worksheet(){ MCAttributes = new MarkupCompatibilityAttributes(){ Ignorable = "x14ac xr xr2 xr3" }  };
            worksheet12.AddNamespaceDeclaration("r", "http://schemas.openxmlformats.org/officeDocument/2006/relationships");
            worksheet12.AddNamespaceDeclaration("mc", "http://schemas.openxmlformats.org/markup-compatibility/2006");
            worksheet12.AddNamespaceDeclaration("x14ac", "http://schemas.microsoft.com/office/spreadsheetml/2009/9/ac");
            worksheet12.AddNamespaceDeclaration("xr", "http://schemas.microsoft.com/office/spreadsheetml/2014/revision");
            worksheet12.AddNamespaceDeclaration("xr2", "http://schemas.microsoft.com/office/spreadsheetml/2015/revision2");
            worksheet12.AddNamespaceDeclaration("xr3", "http://schemas.microsoft.com/office/spreadsheetml/2016/revision3");
            worksheet12.SetAttribute(new OpenXmlAttribute("xr", "uid", "http://schemas.microsoft.com/office/spreadsheetml/2014/revision", "{00000000-0001-0000-0200-000000000000}"));

            SheetProperties sheetProperties11 = new SheetProperties(){ CodeName = "Sheet3" };
            TabColor tabColor11 = new TabColor(){ Theme = (UInt32Value)9U, Tint = 0.59999389629810485D };
            PageSetupProperties pageSetupProperties11 = new PageSetupProperties(){ FitToPage = true };

            sheetProperties11.Append(tabColor11);
            sheetProperties11.Append(pageSetupProperties11);
            SheetDimension sheetDimension12 = new SheetDimension(){ Reference = "A1:I15" };

            SheetViews sheetViews12 = new SheetViews();
            SheetView sheetView12 = new SheetView(){ ShowGridLines = false, ShowRowColHeaders = false, ZoomScaleNormal = (UInt32Value)100U, WorkbookViewId = (UInt32Value)0U };

            sheetViews12.Append(sheetView12);
            SheetFormatProperties sheetFormatProperties12 = new SheetFormatProperties(){ DefaultColumnWidth = 8.75D, DefaultRowHeight = 13.5D, DyDescent = 0.25D };

            Columns columns12 = new Columns();
            Column column54 = new Column(){ Min = (UInt32Value)1U, Max = (UInt32Value)1U, Width = 1.58203125D, Style = (UInt32Value)1U, CustomWidth = true };
            Column column55 = new Column(){ Min = (UInt32Value)2U, Max = (UInt32Value)8U, Width = 16.58203125D, Style = (UInt32Value)1U, CustomWidth = true };
            Column column56 = new Column(){ Min = (UInt32Value)9U, Max = (UInt32Value)9U, Width = 1.58203125D, Style = (UInt32Value)2U, CustomWidth = true };
            Column column57 = new Column(){ Min = (UInt32Value)10U, Max = (UInt32Value)10U, Width = 8.58203125D, Style = (UInt32Value)2U, CustomWidth = true };
            Column column58 = new Column(){ Min = (UInt32Value)11U, Max = (UInt32Value)16384U, Width = 8.75D, Style = (UInt32Value)2U };

            columns12.Append(column54);
            columns12.Append(column55);
            columns12.Append(column56);
            columns12.Append(column57);
            columns12.Append(column58);

            SheetData sheetData12 = new SheetData();

            Row row156 = new Row(){ RowIndex = (UInt32Value)1U, Spans = new ListValue<StringValue>() { InnerText = "1:9" }, Height = 9D, CustomHeight = true, DyDescent = 0.25D };

            Cell cell1182 = new Cell(){ CellReference = "I1", StyleIndex = (UInt32Value)2U, DataType = CellValues.SharedString };
            CellValue cellValue480 = new CellValue();
            cellValue480.Text = "2";

            cell1182.Append(cellValue480);

            row156.Append(cell1182);

            Row row157 = new Row(){ RowIndex = (UInt32Value)2U, Spans = new ListValue<StringValue>() { InnerText = "1:9" }, Height = 96D, CustomHeight = true, DyDescent = 0.25D };

            Cell cell1183 = new Cell(){ CellReference = "B2", StyleIndex = (UInt32Value)52U, DataType = CellValues.String };
            CellFormula cellFormula141 = new CellFormula();
            cellFormula141.Text = "\"March \"&CalendarYear";
            CellValue cellValue481 = new CellValue();
            cellValue481.Text = "March 2019";

            cell1183.Append(cellFormula141);
            cell1183.Append(cellValue481);
            Cell cell1184 = new Cell(){ CellReference = "C2", StyleIndex = (UInt32Value)52U };
            Cell cell1185 = new Cell(){ CellReference = "D2", StyleIndex = (UInt32Value)52U };
            Cell cell1186 = new Cell(){ CellReference = "E2", StyleIndex = (UInt32Value)3U };
            Cell cell1187 = new Cell(){ CellReference = "F2", StyleIndex = (UInt32Value)3U };
            Cell cell1188 = new Cell(){ CellReference = "G2", StyleIndex = (UInt32Value)3U };
            Cell cell1189 = new Cell(){ CellReference = "H2", StyleIndex = (UInt32Value)4U };

            row157.Append(cell1183);
            row157.Append(cell1184);
            row157.Append(cell1185);
            row157.Append(cell1186);
            row157.Append(cell1187);
            row157.Append(cell1188);
            row157.Append(cell1189);

            Row row158 = new Row(){ RowIndex = (UInt32Value)3U, Spans = new ListValue<StringValue>() { InnerText = "1:9" }, StyleIndex = (UInt32Value)13U, CustomFormat = true, Height = 24D, CustomHeight = true, DyDescent = 0.25D };
            Cell cell1190 = new Cell(){ CellReference = "A3", StyleIndex = (UInt32Value)12U };

            Cell cell1191 = new Cell(){ CellReference = "B3", StyleIndex = (UInt32Value)25U, DataType = CellValues.String };
            CellFormula cellFormula142 = new CellFormula();
            cellFormula142.Text = "WeekStart";
            CellValue cellValue482 = new CellValue();
            cellValue482.Text = "Sunday";

            cell1191.Append(cellFormula142);
            cell1191.Append(cellValue482);

            Cell cell1192 = new Cell(){ CellReference = "C3", StyleIndex = (UInt32Value)26U, DataType = CellValues.String };
            CellFormula cellFormula143 = new CellFormula(){ FormulaType = CellFormulaValues.Shared, Reference = "C3:H3", SharedIndex = (UInt32Value)0U };
            cellFormula143.Text = "TEXT(C4,\"dddd\")";
            CellValue cellValue483 = new CellValue();
            cellValue483.Text = "Monday";

            cell1192.Append(cellFormula143);
            cell1192.Append(cellValue483);

            Cell cell1193 = new Cell(){ CellReference = "D3", StyleIndex = (UInt32Value)26U, DataType = CellValues.String };
            CellFormula cellFormula144 = new CellFormula(){ FormulaType = CellFormulaValues.Shared, SharedIndex = (UInt32Value)0U };
            cellFormula144.Text = "";
            CellValue cellValue484 = new CellValue();
            cellValue484.Text = "Tuesday";

            cell1193.Append(cellFormula144);
            cell1193.Append(cellValue484);

            Cell cell1194 = new Cell(){ CellReference = "E3", StyleIndex = (UInt32Value)26U, DataType = CellValues.String };
            CellFormula cellFormula145 = new CellFormula(){ FormulaType = CellFormulaValues.Shared, SharedIndex = (UInt32Value)0U };
            cellFormula145.Text = "";
            CellValue cellValue485 = new CellValue();
            cellValue485.Text = "Wednesday";

            cell1194.Append(cellFormula145);
            cell1194.Append(cellValue485);

            Cell cell1195 = new Cell(){ CellReference = "F3", StyleIndex = (UInt32Value)26U, DataType = CellValues.String };
            CellFormula cellFormula146 = new CellFormula(){ FormulaType = CellFormulaValues.Shared, SharedIndex = (UInt32Value)0U };
            cellFormula146.Text = "";
            CellValue cellValue486 = new CellValue();
            cellValue486.Text = "Thursday";

            cell1195.Append(cellFormula146);
            cell1195.Append(cellValue486);

            Cell cell1196 = new Cell(){ CellReference = "G3", StyleIndex = (UInt32Value)26U, DataType = CellValues.String };
            CellFormula cellFormula147 = new CellFormula(){ FormulaType = CellFormulaValues.Shared, SharedIndex = (UInt32Value)0U };
            cellFormula147.Text = "";
            CellValue cellValue487 = new CellValue();
            cellValue487.Text = "Friday";

            cell1196.Append(cellFormula147);
            cell1196.Append(cellValue487);

            Cell cell1197 = new Cell(){ CellReference = "H3", StyleIndex = (UInt32Value)27U, DataType = CellValues.String };
            CellFormula cellFormula148 = new CellFormula(){ FormulaType = CellFormulaValues.Shared, SharedIndex = (UInt32Value)0U };
            cellFormula148.Text = "";
            CellValue cellValue488 = new CellValue();
            cellValue488.Text = "Saturday";

            cell1197.Append(cellFormula148);
            cell1197.Append(cellValue488);

            row158.Append(cell1190);
            row158.Append(cell1191);
            row158.Append(cell1192);
            row158.Append(cell1193);
            row158.Append(cell1194);
            row158.Append(cell1195);
            row158.Append(cell1196);
            row158.Append(cell1197);

            Row row159 = new Row(){ RowIndex = (UInt32Value)4U, Spans = new ListValue<StringValue>() { InnerText = "1:9" }, StyleIndex = (UInt32Value)6U, CustomFormat = true, Height = 24D, CustomHeight = true, DyDescent = 0.35D };
            Cell cell1198 = new Cell(){ CellReference = "A4", StyleIndex = (UInt32Value)5U };

            Cell cell1199 = new Cell(){ CellReference = "B4", StyleIndex = (UInt32Value)28U };
            CellFormula cellFormula149 = new CellFormula(){ FormulaType = CellFormulaValues.Array, Reference = "B4:H4" };
            cellFormula149.Text = "DaysAndWeeks+DATE(CalendarYear,3,1)-WEEKDAY(DATE(CalendarYear,3,1),(WeekStart=\"Monday\")+1)+1";
            CellValue cellValue489 = new CellValue();
            cellValue489.Text = "43520";

            cell1199.Append(cellFormula149);
            cell1199.Append(cellValue489);

            Cell cell1200 = new Cell(){ CellReference = "C4", StyleIndex = (UInt32Value)28U };
            CellValue cellValue490 = new CellValue();
            cellValue490.Text = "43521";

            cell1200.Append(cellValue490);

            Cell cell1201 = new Cell(){ CellReference = "D4", StyleIndex = (UInt32Value)28U };
            CellValue cellValue491 = new CellValue();
            cellValue491.Text = "43522";

            cell1201.Append(cellValue491);

            Cell cell1202 = new Cell(){ CellReference = "E4", StyleIndex = (UInt32Value)28U };
            CellValue cellValue492 = new CellValue();
            cellValue492.Text = "43523";

            cell1202.Append(cellValue492);

            Cell cell1203 = new Cell(){ CellReference = "F4", StyleIndex = (UInt32Value)28U };
            CellValue cellValue493 = new CellValue();
            cellValue493.Text = "43524";

            cell1203.Append(cellValue493);

            Cell cell1204 = new Cell(){ CellReference = "G4", StyleIndex = (UInt32Value)28U };
            CellValue cellValue494 = new CellValue();
            cellValue494.Text = "43525";

            cell1204.Append(cellValue494);

            Cell cell1205 = new Cell(){ CellReference = "H4", StyleIndex = (UInt32Value)28U };
            CellValue cellValue495 = new CellValue();
            cellValue495.Text = "43526";

            cell1205.Append(cellValue495);

            row159.Append(cell1198);
            row159.Append(cell1199);
            row159.Append(cell1200);
            row159.Append(cell1201);
            row159.Append(cell1202);
            row159.Append(cell1203);
            row159.Append(cell1204);
            row159.Append(cell1205);

            Row row160 = new Row(){ RowIndex = (UInt32Value)5U, Spans = new ListValue<StringValue>() { InnerText = "1:9" }, StyleIndex = (UInt32Value)18U, CustomFormat = true, Height = 56.15D, CustomHeight = true, DyDescent = 0.25D };
            Cell cell1206 = new Cell(){ CellReference = "A5", StyleIndex = (UInt32Value)17U };
            Cell cell1207 = new Cell(){ CellReference = "B5", StyleIndex = (UInt32Value)30U };
            Cell cell1208 = new Cell(){ CellReference = "C5", StyleIndex = (UInt32Value)30U };
            Cell cell1209 = new Cell(){ CellReference = "D5", StyleIndex = (UInt32Value)30U };
            Cell cell1210 = new Cell(){ CellReference = "E5", StyleIndex = (UInt32Value)30U };
            Cell cell1211 = new Cell(){ CellReference = "F5", StyleIndex = (UInt32Value)30U };
            Cell cell1212 = new Cell(){ CellReference = "G5", StyleIndex = (UInt32Value)30U };
            Cell cell1213 = new Cell(){ CellReference = "H5", StyleIndex = (UInt32Value)30U };

            row160.Append(cell1206);
            row160.Append(cell1207);
            row160.Append(cell1208);
            row160.Append(cell1209);
            row160.Append(cell1210);
            row160.Append(cell1211);
            row160.Append(cell1212);
            row160.Append(cell1213);

            Row row161 = new Row(){ RowIndex = (UInt32Value)6U, Spans = new ListValue<StringValue>() { InnerText = "1:9" }, StyleIndex = (UInt32Value)6U, CustomFormat = true, Height = 24D, CustomHeight = true, DyDescent = 0.25D };
            Cell cell1214 = new Cell(){ CellReference = "A6", StyleIndex = (UInt32Value)5U };

            Cell cell1215 = new Cell(){ CellReference = "B6", StyleIndex = (UInt32Value)31U };
            CellFormula cellFormula150 = new CellFormula(){ FormulaType = CellFormulaValues.Array, Reference = "B6:H6" };
            cellFormula150.Text = "DaysAndWeeks+DATE(CalendarYear,3,1)-WEEKDAY(DATE(CalendarYear,3,1),(WeekStart=\"Monday\")+1)+8";
            CellValue cellValue496 = new CellValue();
            cellValue496.Text = "43527";

            cell1215.Append(cellFormula150);
            cell1215.Append(cellValue496);

            Cell cell1216 = new Cell(){ CellReference = "C6", StyleIndex = (UInt32Value)31U };
            CellValue cellValue497 = new CellValue();
            cellValue497.Text = "43528";

            cell1216.Append(cellValue497);

            Cell cell1217 = new Cell(){ CellReference = "D6", StyleIndex = (UInt32Value)31U };
            CellValue cellValue498 = new CellValue();
            cellValue498.Text = "43529";

            cell1217.Append(cellValue498);

            Cell cell1218 = new Cell(){ CellReference = "E6", StyleIndex = (UInt32Value)31U };
            CellValue cellValue499 = new CellValue();
            cellValue499.Text = "43530";

            cell1218.Append(cellValue499);

            Cell cell1219 = new Cell(){ CellReference = "F6", StyleIndex = (UInt32Value)31U };
            CellValue cellValue500 = new CellValue();
            cellValue500.Text = "43531";

            cell1219.Append(cellValue500);

            Cell cell1220 = new Cell(){ CellReference = "G6", StyleIndex = (UInt32Value)31U };
            CellValue cellValue501 = new CellValue();
            cellValue501.Text = "43532";

            cell1220.Append(cellValue501);

            Cell cell1221 = new Cell(){ CellReference = "H6", StyleIndex = (UInt32Value)31U };
            CellValue cellValue502 = new CellValue();
            cellValue502.Text = "43533";

            cell1221.Append(cellValue502);

            row161.Append(cell1214);
            row161.Append(cell1215);
            row161.Append(cell1216);
            row161.Append(cell1217);
            row161.Append(cell1218);
            row161.Append(cell1219);
            row161.Append(cell1220);
            row161.Append(cell1221);

            Row row162 = new Row(){ RowIndex = (UInt32Value)7U, Spans = new ListValue<StringValue>() { InnerText = "1:9" }, StyleIndex = (UInt32Value)18U, CustomFormat = true, Height = 56.15D, CustomHeight = true, DyDescent = 0.25D };
            Cell cell1222 = new Cell(){ CellReference = "A7", StyleIndex = (UInt32Value)17U };
            Cell cell1223 = new Cell(){ CellReference = "B7", StyleIndex = (UInt32Value)29U };
            Cell cell1224 = new Cell(){ CellReference = "C7", StyleIndex = (UInt32Value)29U };
            Cell cell1225 = new Cell(){ CellReference = "D7", StyleIndex = (UInt32Value)29U };
            Cell cell1226 = new Cell(){ CellReference = "E7", StyleIndex = (UInt32Value)29U };
            Cell cell1227 = new Cell(){ CellReference = "F7", StyleIndex = (UInt32Value)29U };
            Cell cell1228 = new Cell(){ CellReference = "G7", StyleIndex = (UInt32Value)29U };
            Cell cell1229 = new Cell(){ CellReference = "H7", StyleIndex = (UInt32Value)29U };

            row162.Append(cell1222);
            row162.Append(cell1223);
            row162.Append(cell1224);
            row162.Append(cell1225);
            row162.Append(cell1226);
            row162.Append(cell1227);
            row162.Append(cell1228);
            row162.Append(cell1229);

            Row row163 = new Row(){ RowIndex = (UInt32Value)8U, Spans = new ListValue<StringValue>() { InnerText = "1:9" }, StyleIndex = (UInt32Value)6U, CustomFormat = true, Height = 24D, CustomHeight = true, DyDescent = 0.25D };
            Cell cell1230 = new Cell(){ CellReference = "A8", StyleIndex = (UInt32Value)5U };

            Cell cell1231 = new Cell(){ CellReference = "B8", StyleIndex = (UInt32Value)32U };
            CellFormula cellFormula151 = new CellFormula(){ FormulaType = CellFormulaValues.Array, Reference = "B8:H8" };
            cellFormula151.Text = "DaysAndWeeks+DATE(CalendarYear,3,1)-WEEKDAY(DATE(CalendarYear,3,1),(WeekStart=\"Monday\")+1)+15";
            CellValue cellValue503 = new CellValue();
            cellValue503.Text = "43534";

            cell1231.Append(cellFormula151);
            cell1231.Append(cellValue503);

            Cell cell1232 = new Cell(){ CellReference = "C8", StyleIndex = (UInt32Value)32U };
            CellValue cellValue504 = new CellValue();
            cellValue504.Text = "43535";

            cell1232.Append(cellValue504);

            Cell cell1233 = new Cell(){ CellReference = "D8", StyleIndex = (UInt32Value)32U };
            CellValue cellValue505 = new CellValue();
            cellValue505.Text = "43536";

            cell1233.Append(cellValue505);

            Cell cell1234 = new Cell(){ CellReference = "E8", StyleIndex = (UInt32Value)32U };
            CellValue cellValue506 = new CellValue();
            cellValue506.Text = "43537";

            cell1234.Append(cellValue506);

            Cell cell1235 = new Cell(){ CellReference = "F8", StyleIndex = (UInt32Value)32U };
            CellValue cellValue507 = new CellValue();
            cellValue507.Text = "43538";

            cell1235.Append(cellValue507);

            Cell cell1236 = new Cell(){ CellReference = "G8", StyleIndex = (UInt32Value)32U };
            CellValue cellValue508 = new CellValue();
            cellValue508.Text = "43539";

            cell1236.Append(cellValue508);

            Cell cell1237 = new Cell(){ CellReference = "H8", StyleIndex = (UInt32Value)32U };
            CellValue cellValue509 = new CellValue();
            cellValue509.Text = "43540";

            cell1237.Append(cellValue509);

            row163.Append(cell1230);
            row163.Append(cell1231);
            row163.Append(cell1232);
            row163.Append(cell1233);
            row163.Append(cell1234);
            row163.Append(cell1235);
            row163.Append(cell1236);
            row163.Append(cell1237);

            Row row164 = new Row(){ RowIndex = (UInt32Value)9U, Spans = new ListValue<StringValue>() { InnerText = "1:9" }, StyleIndex = (UInt32Value)18U, CustomFormat = true, Height = 56.15D, CustomHeight = true, DyDescent = 0.25D };
            Cell cell1238 = new Cell(){ CellReference = "A9", StyleIndex = (UInt32Value)17U };
            Cell cell1239 = new Cell(){ CellReference = "B9", StyleIndex = (UInt32Value)30U };
            Cell cell1240 = new Cell(){ CellReference = "C9", StyleIndex = (UInt32Value)30U };
            Cell cell1241 = new Cell(){ CellReference = "D9", StyleIndex = (UInt32Value)30U };
            Cell cell1242 = new Cell(){ CellReference = "E9", StyleIndex = (UInt32Value)30U };
            Cell cell1243 = new Cell(){ CellReference = "F9", StyleIndex = (UInt32Value)30U };
            Cell cell1244 = new Cell(){ CellReference = "G9", StyleIndex = (UInt32Value)30U };
            Cell cell1245 = new Cell(){ CellReference = "H9", StyleIndex = (UInt32Value)30U };

            row164.Append(cell1238);
            row164.Append(cell1239);
            row164.Append(cell1240);
            row164.Append(cell1241);
            row164.Append(cell1242);
            row164.Append(cell1243);
            row164.Append(cell1244);
            row164.Append(cell1245);

            Row row165 = new Row(){ RowIndex = (UInt32Value)10U, Spans = new ListValue<StringValue>() { InnerText = "1:9" }, StyleIndex = (UInt32Value)6U, CustomFormat = true, Height = 24D, CustomHeight = true, DyDescent = 0.25D };
            Cell cell1246 = new Cell(){ CellReference = "A10", StyleIndex = (UInt32Value)5U };

            Cell cell1247 = new Cell(){ CellReference = "B10", StyleIndex = (UInt32Value)31U };
            CellFormula cellFormula152 = new CellFormula(){ FormulaType = CellFormulaValues.Array, Reference = "B10:H10" };
            cellFormula152.Text = "DaysAndWeeks+DATE(CalendarYear,3,1)-WEEKDAY(DATE(CalendarYear,3,1),(WeekStart=\"Monday\")+1)+22";
            CellValue cellValue510 = new CellValue();
            cellValue510.Text = "43541";

            cell1247.Append(cellFormula152);
            cell1247.Append(cellValue510);

            Cell cell1248 = new Cell(){ CellReference = "C10", StyleIndex = (UInt32Value)31U };
            CellValue cellValue511 = new CellValue();
            cellValue511.Text = "43542";

            cell1248.Append(cellValue511);

            Cell cell1249 = new Cell(){ CellReference = "D10", StyleIndex = (UInt32Value)31U };
            CellValue cellValue512 = new CellValue();
            cellValue512.Text = "43543";

            cell1249.Append(cellValue512);

            Cell cell1250 = new Cell(){ CellReference = "E10", StyleIndex = (UInt32Value)31U };
            CellValue cellValue513 = new CellValue();
            cellValue513.Text = "43544";

            cell1250.Append(cellValue513);

            Cell cell1251 = new Cell(){ CellReference = "F10", StyleIndex = (UInt32Value)31U };
            CellValue cellValue514 = new CellValue();
            cellValue514.Text = "43545";

            cell1251.Append(cellValue514);

            Cell cell1252 = new Cell(){ CellReference = "G10", StyleIndex = (UInt32Value)31U };
            CellValue cellValue515 = new CellValue();
            cellValue515.Text = "43546";

            cell1252.Append(cellValue515);

            Cell cell1253 = new Cell(){ CellReference = "H10", StyleIndex = (UInt32Value)31U };
            CellValue cellValue516 = new CellValue();
            cellValue516.Text = "43547";

            cell1253.Append(cellValue516);

            row165.Append(cell1246);
            row165.Append(cell1247);
            row165.Append(cell1248);
            row165.Append(cell1249);
            row165.Append(cell1250);
            row165.Append(cell1251);
            row165.Append(cell1252);
            row165.Append(cell1253);

            Row row166 = new Row(){ RowIndex = (UInt32Value)11U, Spans = new ListValue<StringValue>() { InnerText = "1:9" }, StyleIndex = (UInt32Value)18U, CustomFormat = true, Height = 56.15D, CustomHeight = true, DyDescent = 0.25D };
            Cell cell1254 = new Cell(){ CellReference = "A11", StyleIndex = (UInt32Value)17U };
            Cell cell1255 = new Cell(){ CellReference = "B11", StyleIndex = (UInt32Value)29U };
            Cell cell1256 = new Cell(){ CellReference = "C11", StyleIndex = (UInt32Value)29U };
            Cell cell1257 = new Cell(){ CellReference = "D11", StyleIndex = (UInt32Value)29U };
            Cell cell1258 = new Cell(){ CellReference = "E11", StyleIndex = (UInt32Value)29U };
            Cell cell1259 = new Cell(){ CellReference = "F11", StyleIndex = (UInt32Value)29U };
            Cell cell1260 = new Cell(){ CellReference = "G11", StyleIndex = (UInt32Value)29U };
            Cell cell1261 = new Cell(){ CellReference = "H11", StyleIndex = (UInt32Value)29U };

            row166.Append(cell1254);
            row166.Append(cell1255);
            row166.Append(cell1256);
            row166.Append(cell1257);
            row166.Append(cell1258);
            row166.Append(cell1259);
            row166.Append(cell1260);
            row166.Append(cell1261);

            Row row167 = new Row(){ RowIndex = (UInt32Value)12U, Spans = new ListValue<StringValue>() { InnerText = "1:9" }, StyleIndex = (UInt32Value)6U, CustomFormat = true, Height = 24D, CustomHeight = true, DyDescent = 0.25D };
            Cell cell1262 = new Cell(){ CellReference = "A12", StyleIndex = (UInt32Value)5U };

            Cell cell1263 = new Cell(){ CellReference = "B12", StyleIndex = (UInt32Value)32U };
            CellFormula cellFormula153 = new CellFormula(){ FormulaType = CellFormulaValues.Array, Reference = "B12:H12" };
            cellFormula153.Text = "DaysAndWeeks+DATE(CalendarYear,3,1)-WEEKDAY(DATE(CalendarYear,3,1),(WeekStart=\"Monday\")+1)+29";
            CellValue cellValue517 = new CellValue();
            cellValue517.Text = "43548";

            cell1263.Append(cellFormula153);
            cell1263.Append(cellValue517);

            Cell cell1264 = new Cell(){ CellReference = "C12", StyleIndex = (UInt32Value)32U };
            CellValue cellValue518 = new CellValue();
            cellValue518.Text = "43549";

            cell1264.Append(cellValue518);

            Cell cell1265 = new Cell(){ CellReference = "D12", StyleIndex = (UInt32Value)32U };
            CellValue cellValue519 = new CellValue();
            cellValue519.Text = "43550";

            cell1265.Append(cellValue519);

            Cell cell1266 = new Cell(){ CellReference = "E12", StyleIndex = (UInt32Value)32U };
            CellValue cellValue520 = new CellValue();
            cellValue520.Text = "43551";

            cell1266.Append(cellValue520);

            Cell cell1267 = new Cell(){ CellReference = "F12", StyleIndex = (UInt32Value)32U };
            CellValue cellValue521 = new CellValue();
            cellValue521.Text = "43552";

            cell1267.Append(cellValue521);

            Cell cell1268 = new Cell(){ CellReference = "G12", StyleIndex = (UInt32Value)32U };
            CellValue cellValue522 = new CellValue();
            cellValue522.Text = "43553";

            cell1268.Append(cellValue522);

            Cell cell1269 = new Cell(){ CellReference = "H12", StyleIndex = (UInt32Value)32U };
            CellValue cellValue523 = new CellValue();
            cellValue523.Text = "43554";

            cell1269.Append(cellValue523);

            row167.Append(cell1262);
            row167.Append(cell1263);
            row167.Append(cell1264);
            row167.Append(cell1265);
            row167.Append(cell1266);
            row167.Append(cell1267);
            row167.Append(cell1268);
            row167.Append(cell1269);

            Row row168 = new Row(){ RowIndex = (UInt32Value)13U, Spans = new ListValue<StringValue>() { InnerText = "1:9" }, StyleIndex = (UInt32Value)18U, CustomFormat = true, Height = 56.15D, CustomHeight = true, DyDescent = 0.25D };
            Cell cell1270 = new Cell(){ CellReference = "A13", StyleIndex = (UInt32Value)17U };
            Cell cell1271 = new Cell(){ CellReference = "B13", StyleIndex = (UInt32Value)30U };
            Cell cell1272 = new Cell(){ CellReference = "C13", StyleIndex = (UInt32Value)30U };
            Cell cell1273 = new Cell(){ CellReference = "D13", StyleIndex = (UInt32Value)30U };
            Cell cell1274 = new Cell(){ CellReference = "E13", StyleIndex = (UInt32Value)30U };
            Cell cell1275 = new Cell(){ CellReference = "F13", StyleIndex = (UInt32Value)30U };
            Cell cell1276 = new Cell(){ CellReference = "G13", StyleIndex = (UInt32Value)30U };
            Cell cell1277 = new Cell(){ CellReference = "H13", StyleIndex = (UInt32Value)30U };

            row168.Append(cell1270);
            row168.Append(cell1271);
            row168.Append(cell1272);
            row168.Append(cell1273);
            row168.Append(cell1274);
            row168.Append(cell1275);
            row168.Append(cell1276);
            row168.Append(cell1277);

            Row row169 = new Row(){ RowIndex = (UInt32Value)14U, Spans = new ListValue<StringValue>() { InnerText = "1:9" }, StyleIndex = (UInt32Value)6U, CustomFormat = true, Height = 24D, CustomHeight = true, DyDescent = 0.25D };
            Cell cell1278 = new Cell(){ CellReference = "A14", StyleIndex = (UInt32Value)5U };

            Cell cell1279 = new Cell(){ CellReference = "B14", StyleIndex = (UInt32Value)31U };
            CellFormula cellFormula154 = new CellFormula(){ FormulaType = CellFormulaValues.Array, Reference = "B14:C14" };
            cellFormula154.Text = "DaysAndWeeks+DATE(CalendarYear,3,1)-WEEKDAY(DATE(CalendarYear,3,1),(WeekStart=\"Monday\")+1)+36";
            CellValue cellValue524 = new CellValue();
            cellValue524.Text = "43555";

            cell1279.Append(cellFormula154);
            cell1279.Append(cellValue524);

            Cell cell1280 = new Cell(){ CellReference = "C14", StyleIndex = (UInt32Value)31U };
            CellValue cellValue525 = new CellValue();
            cellValue525.Text = "43556";

            cell1280.Append(cellValue525);

            Cell cell1281 = new Cell(){ CellReference = "D14", StyleIndex = (UInt32Value)53U, DataType = CellValues.SharedString };
            CellValue cellValue526 = new CellValue();
            cellValue526.Text = "1";

            cell1281.Append(cellValue526);
            Cell cell1282 = new Cell(){ CellReference = "E14", StyleIndex = (UInt32Value)53U };
            Cell cell1283 = new Cell(){ CellReference = "F14", StyleIndex = (UInt32Value)53U };
            Cell cell1284 = new Cell(){ CellReference = "G14", StyleIndex = (UInt32Value)53U };
            Cell cell1285 = new Cell(){ CellReference = "H14", StyleIndex = (UInt32Value)54U };

            row169.Append(cell1278);
            row169.Append(cell1279);
            row169.Append(cell1280);
            row169.Append(cell1281);
            row169.Append(cell1282);
            row169.Append(cell1283);
            row169.Append(cell1284);
            row169.Append(cell1285);

            Row row170 = new Row(){ RowIndex = (UInt32Value)15U, Spans = new ListValue<StringValue>() { InnerText = "1:9" }, StyleIndex = (UInt32Value)18U, CustomFormat = true, Height = 56.15D, CustomHeight = true, DyDescent = 0.25D };
            Cell cell1286 = new Cell(){ CellReference = "A15", StyleIndex = (UInt32Value)17U };
            Cell cell1287 = new Cell(){ CellReference = "B15", StyleIndex = (UInt32Value)29U };
            Cell cell1288 = new Cell(){ CellReference = "C15", StyleIndex = (UInt32Value)29U };
            Cell cell1289 = new Cell(){ CellReference = "D15", StyleIndex = (UInt32Value)55U };
            Cell cell1290 = new Cell(){ CellReference = "E15", StyleIndex = (UInt32Value)55U };
            Cell cell1291 = new Cell(){ CellReference = "F15", StyleIndex = (UInt32Value)55U };
            Cell cell1292 = new Cell(){ CellReference = "G15", StyleIndex = (UInt32Value)55U };
            Cell cell1293 = new Cell(){ CellReference = "H15", StyleIndex = (UInt32Value)56U };

            row170.Append(cell1286);
            row170.Append(cell1287);
            row170.Append(cell1288);
            row170.Append(cell1289);
            row170.Append(cell1290);
            row170.Append(cell1291);
            row170.Append(cell1292);
            row170.Append(cell1293);

            sheetData12.Append(row156);
            sheetData12.Append(row157);
            sheetData12.Append(row158);
            sheetData12.Append(row159);
            sheetData12.Append(row160);
            sheetData12.Append(row161);
            sheetData12.Append(row162);
            sheetData12.Append(row163);
            sheetData12.Append(row164);
            sheetData12.Append(row165);
            sheetData12.Append(row166);
            sheetData12.Append(row167);
            sheetData12.Append(row168);
            sheetData12.Append(row169);
            sheetData12.Append(row170);

            MergeCells mergeCells12 = new MergeCells(){ Count = (UInt32Value)3U };
            MergeCell mergeCell36 = new MergeCell(){ Reference = "B2:D2" };
            MergeCell mergeCell37 = new MergeCell(){ Reference = "D14:H14" };
            MergeCell mergeCell38 = new MergeCell(){ Reference = "D15:H15" };

            mergeCells12.Append(mergeCell36);
            mergeCells12.Append(mergeCell37);
            mergeCells12.Append(mergeCell38);

            ConditionalFormatting conditionalFormatting21 = new ConditionalFormatting(){ SequenceOfReferences = new ListValue<StringValue>() { InnerText = "B12:H12 B14:C14" } };

            ConditionalFormattingRule conditionalFormattingRule21 = new ConditionalFormattingRule(){ Type = ConditionalFormatValues.Expression, FormatId = (UInt32Value)19U, Priority = 2 };
            Formula formula21 = new Formula();
            formula21.Text = "AND(DAY(B12)>=1,DAY(B12)<=15)";

            conditionalFormattingRule21.Append(formula21);

            conditionalFormatting21.Append(conditionalFormattingRule21);

            ConditionalFormatting conditionalFormatting22 = new ConditionalFormatting(){ SequenceOfReferences = new ListValue<StringValue>() { InnerText = "B4:G4" } };

            ConditionalFormattingRule conditionalFormattingRule22 = new ConditionalFormattingRule(){ Type = ConditionalFormatValues.Expression, FormatId = (UInt32Value)18U, Priority = 1 };
            Formula formula22 = new Formula();
            formula22.Text = "DAY(B4)>8";

            conditionalFormattingRule22.Append(formula22);

            conditionalFormatting22.Append(conditionalFormattingRule22);

            DataValidations dataValidations11 = new DataValidations(){ Count = (UInt32Value)8U };

            DataValidation dataValidation86 = new DataValidation(){ AllowBlank = true, ShowInputMessage = true, ShowErrorMessage = true, Prompt = "March month calendar", SequenceOfReferences = new ListValue<StringValue>() { InnerText = "A1" } };
            dataValidation86.SetAttribute(new OpenXmlAttribute("xr", "uid", "http://schemas.microsoft.com/office/spreadsheetml/2014/revision", "{00000000-0002-0000-0200-000000000000}"));

            DataValidation dataValidation87 = new DataValidation(){ AllowBlank = true, ShowInputMessage = true, ShowErrorMessage = true, Prompt = "The year in this cell is automatically updated based on year entered in January worksheet. Calendar below has dates for previous and next month with lighter font shade", SequenceOfReferences = new ListValue<StringValue>() { InnerText = "B2:D2" } };
            dataValidation87.SetAttribute(new OpenXmlAttribute("xr", "uid", "http://schemas.microsoft.com/office/spreadsheetml/2014/revision", "{00000000-0002-0000-0200-000001000000}"));

            DataValidation dataValidation88 = new DataValidation(){ AllowBlank = true, ShowInputMessage = true, ShowErrorMessage = true, Prompt = "Automatically determined weekday", SequenceOfReferences = new ListValue<StringValue>() { InnerText = "C3:H3" } };
            dataValidation88.SetAttribute(new OpenXmlAttribute("xr", "uid", "http://schemas.microsoft.com/office/spreadsheetml/2014/revision", "{00000000-0002-0000-0200-000002000000}"));

            DataValidation dataValidation89 = new DataValidation(){ AllowBlank = true, ShowInputMessage = true, ShowErrorMessage = true, Prompt = "This row & rows 6, 8, 10, 12 & 14 contain calendar days of the week. If this cell doesn’t contain the number 1, then it is a day from the previous month. Enter notes in cell D15.", SequenceOfReferences = new ListValue<StringValue>() { InnerText = "B4" } };
            dataValidation89.SetAttribute(new OpenXmlAttribute("xr", "uid", "http://schemas.microsoft.com/office/spreadsheetml/2014/revision", "{00000000-0002-0000-0200-000003000000}"));

            DataValidation dataValidation90 = new DataValidation(){ AllowBlank = true, ShowInputMessage = true, ShowErrorMessage = true, Prompt = "This row & rows 7, 9, 11, 13, & 15 are cells for entering daily notes related to the calendar day in the cell above.", SequenceOfReferences = new ListValue<StringValue>() { InnerText = "B5" } };
            dataValidation90.SetAttribute(new OpenXmlAttribute("xr", "uid", "http://schemas.microsoft.com/office/spreadsheetml/2014/revision", "{00000000-0002-0000-0200-000004000000}"));

            DataValidation dataValidation91 = new DataValidation(){ AllowBlank = true, ShowInputMessage = true, Prompt = "Enter monthly Notes in this cell", SequenceOfReferences = new ListValue<StringValue>() { InnerText = "D15:H15" } };
            dataValidation91.SetAttribute(new OpenXmlAttribute("xr", "uid", "http://schemas.microsoft.com/office/spreadsheetml/2014/revision", "{00000000-0002-0000-0200-000005000000}"));

            DataValidation dataValidation92 = new DataValidation(){ AllowBlank = true, ShowInputMessage = true, Prompt = "Enter monthly Notes in cell below", SequenceOfReferences = new ListValue<StringValue>() { InnerText = "D14:H14" } };
            dataValidation92.SetAttribute(new OpenXmlAttribute("xr", "uid", "http://schemas.microsoft.com/office/spreadsheetml/2014/revision", "{00000000-0002-0000-0200-000006000000}"));

            DataValidation dataValidation93 = new DataValidation(){ AllowBlank = true, ShowInputMessage = true, ShowErrorMessage = true, Prompt = "This row contains weekday names for this calendar. This cell contains the starting day of the week. To change week start day, select a new weekday in January worksheet cell L5.", SequenceOfReferences = new ListValue<StringValue>() { InnerText = "B3" } };
            dataValidation93.SetAttribute(new OpenXmlAttribute("xr", "uid", "http://schemas.microsoft.com/office/spreadsheetml/2014/revision", "{00000000-0002-0000-0200-000007000000}"));

            dataValidations11.Append(dataValidation86);
            dataValidations11.Append(dataValidation87);
            dataValidations11.Append(dataValidation88);
            dataValidations11.Append(dataValidation89);
            dataValidations11.Append(dataValidation90);
            dataValidations11.Append(dataValidation91);
            dataValidations11.Append(dataValidation92);
            dataValidations11.Append(dataValidation93);
            PrintOptions printOptions11 = new PrintOptions(){ HorizontalCentered = true };
            PageMargins pageMargins12 = new PageMargins(){ Left = 0.25D, Right = 0.25D, Top = 0.5D, Bottom = 0.5D, Header = 0.3D, Footer = 0.3D };
            PageSetup pageSetup11 = new PageSetup(){ Orientation = OrientationValues.Landscape, Id = "rId1" };
            HeaderFooter headerFooter11 = new HeaderFooter(){ DifferentFirst = true };
            Drawing drawing11 = new Drawing(){ Id = "rId2" };

            worksheet12.Append(sheetProperties11);
            worksheet12.Append(sheetDimension12);
            worksheet12.Append(sheetViews12);
            worksheet12.Append(sheetFormatProperties12);
            worksheet12.Append(columns12);
            worksheet12.Append(sheetData12);
            worksheet12.Append(mergeCells12);
            worksheet12.Append(conditionalFormatting21);
            worksheet12.Append(conditionalFormatting22);
            worksheet12.Append(dataValidations11);
            worksheet12.Append(printOptions11);
            worksheet12.Append(pageMargins12);
            worksheet12.Append(pageSetup11);
            worksheet12.Append(headerFooter11);
            worksheet12.Append(drawing11);

            worksheetPart12.Worksheet = worksheet12;
        }
 

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.coloradmin.cn/o/2224664.html

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈,一经查实,立即删除!

相关文章

css实现外层不换行,内层换行

css实现上图效果&#xff0c;内容A和B整体不换行&#xff0c;B内容中换行 <div className"description"> <div className"label">{formatMessage({id: description})}</Col> <divclassName"value"> &l…

Pr 视频效果:波形变形

视频效果/扭曲/波形变形 Distort/Wave Warp 波形变形 Wave Warp效果用于在剪辑上创建类似波浪的动态变形效果。 此效果会自动动画化&#xff0c;波形以恒定速度移动。要改变速度或停止波动&#xff0c;需要设置关键帧。 ◆ ◆ ◆ 效果选项说明 通过调整波形的类型、高度、宽度…

一分钟看懂死锁的概念

&#x1f449; 请点赞支持这款 全新设计的脚手架 &#xff0c;让 Java 再次伟大&#xff01; 什么是死锁 当线程 A 持有独占锁 a&#xff0c;并尝试去获取独占锁 b 的同时&#xff0c;线程 B 持有独占锁 b &#xff0c;并尝试获取独占锁 a 的情况下&#xff0c;就会发生 AB 两…

挂耳式耳机品牌排行榜前十名有哪些?平价开放式耳机品牌推荐!

可能我们经常能够看到不少小伙伴佩戴普通蓝牙耳机跑步健身&#xff0c;确实让人羡慕&#xff0c;但我始终觉得入耳式耳机并不适合长时间的运动佩戴。就以我个人为例&#xff0c;由于耳孔较大&#xff0c;普通入耳式耳机在运动中很难稳固地佩戴&#xff0c;经常发生耳机掉落甚至…

SMA-BP时序预测 | Matlab实现SMA-BP黏菌算法优化BP神经网络时间序列预测

SMA-BP时序预测 | Matlab实现SMA-BP黏菌算法优化BP神经网络时间序列预测 目录 SMA-BP时序预测 | Matlab实现SMA-BP黏菌算法优化BP神经网络时间序列预测预测效果基本介绍程序设计参考资料 预测效果 基本介绍 1.Matlab实现SMA-BP黏菌算法优化BP神经网络时间序列预测&#xff08;完…

[论文笔记]ColPali: Efficient Document Retrieval with Vision Language Models

引言 今天带来一篇多模态RAG的论文笔记&#xff1a;ColPali: Efficient Document Retrieval with Vision Language Models。 引入了一种利用视觉语言模型文档理解能力的检索模型架构ColPali&#xff0c;从文档页面图像上生成高质量的上下文嵌入&#xff0c;结合延迟交互匹配机…

算法刷题基础知识总结

文章目录 处理输入输出常用数据结构数学知识数论基础质数和合数因数/约数互为质数 阶乘排列与组合 排序字典序Comparator接口 处理输入输出 Scanner 类可以读取多种类型的数据&#xff0c;包括&#xff1a; nextInt()&#xff1a;读取整数。nextDouble()&#xff1a;读取双精…

vitepress一键push和发布到github部署网站脚本

文章目录 前言一、viteress基本结构二、脚本1、push2、dev 总结 前言 没啥可说的 脚本是bat文件&#xff0c;直接双击运行 提示&#xff1a;以下是本篇文章正文内容&#xff0c;下面案例可供参考 一、viteress基本结构 创建完你的文档&#xff0c;目录如下 ---bin ---docs …

java计算机毕设课设—写字板程序(附源码、文章、相关截图、部署视频)

这是什么系统&#xff1f; 资源获取方式再最下方 java计算机毕设课设—写字板程序(附源码、文章、相关截图、部署视频) 一、项目简介 本毕设旨在开发一个高效、易用的基于Java的写字板程序&#xff0c;通过利用Java的Swing库构建用户界面&#xff0c;实现基本的文本编辑功能…

Ubuntu 22.04系统启动时自动运行ROS2节点

在 Ubuntu 启动时自动运行 ROS2 节点的方法 环境&#xff1a;Ubuntu 系统&#xff0c;ROS2 Humble&#xff0c;使用系统自带的 启动应用程序 目标&#xff1a;在系统启动时自动运行指定的 ROS2 节点 效果展示 系统启动后&#xff0c;自动运行小乌龟节点和键盘控制节点。 实践…

直接删除Github上的文件

直接删除Github上的文件 说明&#xff1a;此操作只删除Github上的文件&#xff0c;本地仓库文件不受影响 1.确定要删除哪个分支文件,以删除main为例&#xff0c; 1.找到本地仓库位置以StudyNote为例&#xff0c;右键 bash here 2.打开命令窗口&#xff0c;将Github的StudyN…

个体能量的勇气层级是否容易达到?

没有勇气面对现实&#xff0c;没有勇气改变自我&#xff0c;没有勇气改变环境&#xff0c;没有勇气创新创造。 这是常态。 如何找寻高质量免费机器人工程资源自学提升-CSDN博客 个人能力的提升&#xff0c;也包括个体能量的提升。 个体能量是个人能力的一个非常重要的衡量指…

微信好友智能管理神器:微动RPA,重塑私域流量构建新纪元 批量自动添加好友

在这个信息爆炸的时代&#xff0c;微信作为私域流量的重要阵地&#xff0c;其好友管理的高效与否直接关乎着个人品牌影响力与商业价值的挖掘。然而&#xff0c;面对海量潜在客户&#xff0c;手动添加好友不仅耗时费力&#xff0c;更可能因频繁操作触发微信风控机制&#xff0c;…

(linux驱动学习 - 12). IIC 驱动实验

目录 一.IIC 总线驱动相关结构体与函数 1.i2c_adapter 结构体 2.i2c_algorithm 结构体 3.向系统注册设置好的 i2c_adapter 结构体 - i2c_add_adapter 4.向系统注册设置好的 i2c_adapter 结构体 - i2c_add_numbered_adapter 5.删除 I2C 适配器 - i2c_del_adapter 二.IIC 设…

影刀RPA实战:验证码识别功能指令

1.影刀官方验证码识别 1.1 介绍 功能&#xff1a;基于AI引擎提供的验证码识别服务&#xff0c;使用影刀内置的AI引擎来识别验证码&#xff0c;使用第三图鉴账号来识别验证码&#xff0c;选填写用户名及密码&#xff0c; 可识别的验证码类型&#xff1a; 纯数字&#xff1a;适…

python学习-第一个小游戏(vscode环境)

学习小甲鱼的视频&#xff0c;写了一个小游戏&#xff0c;vscode环境 运行结果 源码地址&#xff1a; python小游戏-猜数字源码

Visual Studio2022 Profile 工具使用

本篇研究下Visual Studio自带的性能分析工具&#xff0c;针对C代码&#xff0c;基于Visual Studio2022 文章目录 CPU使用率检测并发可视化工具使用率视图线程视图内核视图并发可视化工具SDK 参考资料 CPU使用率 对于CPU密集型程序&#xff0c;我们可以通过分析程序的CPU使用率…

系统架构设计师教程 第2章 2.5 计算机网络 笔记

2.5计算机网络 ★☆☆☆☆ 2.5.1网络的基本概念 1.计算机网络的发展 计算机网络发展&#xff0c;其大致经历了诞生、形成、互联互通和高速发展等4个阶段。 2.计算机网络的功能 1)数据通信 数据通信是依照一定的通信协议&#xff0c;利用数据传 输技术在两个通信结点之间传…

【Spring Boot】元注解

元注解 1.元注解1.1 Target1.2 Retention1.3 Inherited1.4 Documented1.5 interface 2.自定义注解2.1 创建自定义注解类2.2 实现业务逻辑2.3 使用自定义注解 1.元注解 元注解就是定义注解的注解&#xff0c;是 Java 提供的用于定义注解的基本注解。 注解 说明 Retention是注解…

linux中级(NFS服务器)

NFS&#xff1a;用于在NNIX/Linux主机之间进行文件共享的协议 流程&#xff1a;首先服务端开启RPC服务&#xff0c;并开启111端口&#xff0c;服务器端启动NFS服务&#xff0c;并向RPC注册端口信息&#xff0c;客户端启动RPC&#xff0c;向服务器RPC服务请求NFS端口&#xff0…