From 05582c53243cfdf57766172b343a36c33dcc1cf1 Mon Sep 17 00:00:00 2001
From: beautyremain <510112057@qq.com>
Date: Thu, 10 Sep 2020 17:46:24 +0800
Subject: [PATCH 1/4] test01
---
test01.txt | 1 +
1 file changed, 1 insertion(+)
create mode 100644 test01.txt
diff --git a/test01.txt b/test01.txt
new file mode 100644
index 0000000..4d280d3
--- /dev/null
+++ b/test01.txt
@@ -0,0 +1 @@
+测试1
\ No newline at end of file
--
Gitee
From 2ee0ec038ba6bfc1e68c76d2172fc9d0fbcf3938 Mon Sep 17 00:00:00 2001
From: beautyremain <510112057@qq.com>
Date: Wed, 4 Nov 2020 22:25:35 +0800
Subject: [PATCH 2/4] =?UTF-8?q?=E8=A7=A3=E5=86=B3=E4=BA=86=E5=9C=A8kill?=
=?UTF-8?q?=E5=AE=8C=E6=88=90=E4=B9=8B=E5=89=8D=E5=86=8D=E6=AC=A1=E5=BC=95?=
=?UTF-8?q?=E7=94=A8=E7=9A=84=E9=97=AE=E9=A2=98?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
WPFTest/UI/Chapter3/C3_SY3.xaml.cs | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/WPFTest/UI/Chapter3/C3_SY3.xaml.cs b/WPFTest/UI/Chapter3/C3_SY3.xaml.cs
index 82eb8de..adf2078 100644
--- a/WPFTest/UI/Chapter3/C3_SY3.xaml.cs
+++ b/WPFTest/UI/Chapter3/C3_SY3.xaml.cs
@@ -19,6 +19,7 @@ using dll_csharp;
using MsExcel = Microsoft.Office.Interop.Excel;
using System.IO;
using System.Diagnostics;
+using System.Threading;
namespace WPFTest.UI.Chapter3
{
@@ -150,19 +151,22 @@ namespace WPFTest.UI.Chapter3
showComment("正在结束excel进程");
//关闭 excel 进程
Process[] AllProces = Process.GetProcesses();
+ int flag = 0;
for (int j = 0; j < AllProces.Length; j++)
{
string theProcName = AllProces[j].ProcessName;
+ //Console.WriteLine(theProcName);
if (String.Compare(theProcName, "EXCEL") == 0)
{
if (AllProces[j].Responding && !AllProces[j].HasExited)
{
AllProces[j].Kill();
+ flag = j;
}
}
}
//Close excel Process.
-
+ Console.WriteLine(AllProces[1].HasExited);
OpenExcel(dest_file_name);
}
}
@@ -173,6 +177,7 @@ namespace WPFTest.UI.Chapter3
//string tempPath = System.Environment.GetEnvironmentVariable("TEMP");
//var filepath = Path.Combine(tempPath, WordPath);
string excelExePath = "";
+ Thread.Sleep(1000);
Process[] wordProcesses = Process.GetProcessesByName("EXCEL");
foreach (Process process in wordProcesses)
{
--
Gitee
From c80a6852ae79a623d702e08695e31ae1dd45d0a4 Mon Sep 17 00:00:00 2001
From: beautyremain <510112057@qq.com>
Date: Wed, 4 Nov 2020 22:36:18 +0800
Subject: [PATCH 3/4] =?UTF-8?q?=E4=BC=98=E5=8C=96=E4=BA=86=E8=A7=A3?=
=?UTF-8?q?=E5=86=B3=E5=8A=9E=E6=B3=95?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
WPFTest/UI/Chapter3/C3_SY3.xaml.cs | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/WPFTest/UI/Chapter3/C3_SY3.xaml.cs b/WPFTest/UI/Chapter3/C3_SY3.xaml.cs
index adf2078..84a374a 100644
--- a/WPFTest/UI/Chapter3/C3_SY3.xaml.cs
+++ b/WPFTest/UI/Chapter3/C3_SY3.xaml.cs
@@ -161,6 +161,7 @@ namespace WPFTest.UI.Chapter3
if (AllProces[j].Responding && !AllProces[j].HasExited)
{
AllProces[j].Kill();
+ //AllProces[j].WaitForExit();
flag = j;
}
}
@@ -177,7 +178,7 @@ namespace WPFTest.UI.Chapter3
//string tempPath = System.Environment.GetEnvironmentVariable("TEMP");
//var filepath = Path.Combine(tempPath, WordPath);
string excelExePath = "";
- Thread.Sleep(1000);
+ //Thread.Sleep(1000);
Process[] wordProcesses = Process.GetProcessesByName("EXCEL");
foreach (Process process in wordProcesses)
{
--
Gitee
From af1edc8d551b570801c5d5d5893416c846c16d21 Mon Sep 17 00:00:00 2001
From: beautyremain <510112057@qq.com>
Date: Wed, 4 Nov 2020 22:46:35 +0800
Subject: [PATCH 4/4] =?UTF-8?q?=E5=8E=BB=E9=99=A4=E4=BA=86=E4=B8=AA?=
=?UTF-8?q?=E4=BA=BA=E7=9A=84=E4=B8=80=E4=BA=9B=E6=B5=8B=E8=AF=95=E6=96=87?=
=?UTF-8?q?=E4=BB=B6?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
BaseComponents/BaseComponents.csproj | 20 +++++++
DeviceInterfaces/DeviceInterfaces.csproj | 30 ++++++++++
DeviceInterfaces/SimTransaction.cs | 3 +-
DeviceInterfaces/cjk02.snk | Bin 0 -> 596 bytes
Models/Models.csproj | 31 ++++++++++
Models/packages.config | 5 ++
Utils/Utils.csproj | 62 +++++++++++++++++++-
WPFTest/ComTest.cs | 1 +
WPFTest/Properties/AssemblyInfo.cs | 2 +-
WPFTest/UI/Chapter3/C3_SY1.xaml.cs | 2 +-
WPFTest/UI/Chapter3/C3_SY3.xaml.cs | 2 +-
WPFTest/WPFTest.csproj | 70 +++++++++++++++++++----
dll_clr/dll_clr.vcxproj | 6 +-
dll_cpp/dll_cpp.vcxproj | 6 +-
dll_csharp/dll_csharp.csproj | 20 +++++++
wprTest.sln | 24 ++++----
16 files changed, 249 insertions(+), 35 deletions(-)
create mode 100644 DeviceInterfaces/cjk02.snk
create mode 100644 Models/packages.config
diff --git a/BaseComponents/BaseComponents.csproj b/BaseComponents/BaseComponents.csproj
index 59d0469..f70c5c1 100644
--- a/BaseComponents/BaseComponents.csproj
+++ b/BaseComponents/BaseComponents.csproj
@@ -33,6 +33,26 @@
4
false
+
+ true
+ bin\x64\Debug\
+ DEBUG;TRACE
+ full
+ x64
+ 7.3
+ prompt
+ MinimumRecommendedRules.ruleset
+
+
+ bin\x64\Release\
+ TRACE
+ true
+ pdbonly
+ x64
+ 7.3
+ prompt
+ MinimumRecommendedRules.ruleset
+
diff --git a/DeviceInterfaces/DeviceInterfaces.csproj b/DeviceInterfaces/DeviceInterfaces.csproj
index 1f27c86..7f27180 100644
--- a/DeviceInterfaces/DeviceInterfaces.csproj
+++ b/DeviceInterfaces/DeviceInterfaces.csproj
@@ -33,6 +33,33 @@
x64
false
+
+ true
+ bin\x64\Debug\
+ DEBUG;TRACE
+ full
+ x64
+ 7.3
+ prompt
+ MinimumRecommendedRules.ruleset
+ true
+
+
+ bin\x64\Release\
+ TRACE
+ true
+ pdbonly
+ x64
+ 7.3
+ prompt
+ MinimumRecommendedRules.ruleset
+
+
+ true
+
+
+ cjk02.snk
+
@@ -49,6 +76,9 @@
+
+
+