Skip to content

Commit

Permalink
Added support for .NET 6 or later Windows Forms controls
Browse files Browse the repository at this point in the history
  • Loading branch information
EWSoftware committed Jan 3, 2023
1 parent a27565d commit cb77c0b
Show file tree
Hide file tree
Showing 83 changed files with 747 additions and 2,818 deletions.
5 changes: 5 additions & 0 deletions Doc/Content/VersionHistory/VersionHistory.aml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,11 @@ Data Interchange (PDI) Library </legacyBold> over the life of the project.</para
<para>Select a version below to see a description of its changes.</para>

<list class="bullet">
<listItem>
<para>
<link xlink:href="d1d9a1d2-7495-457e-9095-880ab00515a3" />
</para>
</listItem>
<listItem>
<para>
<link xlink:href="3ebeed58-ecb5-475f-93c1-c9e0098ac5a0" />
Expand Down
29 changes: 29 additions & 0 deletions Doc/Content/VersionHistory/v2023.1.2.0.aml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
<?xml version="1.0" encoding="utf-8"?>
<topic id="d1d9a1d2-7495-457e-9095-880ab00515a3" revisionNumber="1">
<developerConceptualDocument xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5" xmlns:xlink="http://www.w3.org/1999/xlink">
<introduction>
<para>Release notes for version 2023.1.2.0.</para>
</introduction>

<section>
<content>
<list class="bullet">
<listItem>
<para>Added support for <codeInline>net6.0-windows</codeInline> to the
<localUri>EWSoftware.PDI.Windows.Forms</localUri> library.</para>
</listItem>

<listItem>
<para>Updated all Windows Forms demo projects to support .NET 6.0.</para>
</listItem>
</list>

</content>
</section>

<relatedTopics>
<link xlink:href="8885fe94-537b-45a2-84e9-112fa9c976ff" />
</relatedTopics>

</developerConceptualDocument>
</topic>
7 changes: 6 additions & 1 deletion Doc/ContentLayout.content
Original file line number Diff line number Diff line change
Expand Up @@ -112,11 +112,16 @@
<HelpKeyword index="K" term="support, donate" />
</HelpKeywords>
</Topic>
<Topic id="8885fe94-537b-45a2-84e9-112fa9c976ff" visible="True" isExpanded="true" isSelected="true" title="Version History">
<Topic id="8885fe94-537b-45a2-84e9-112fa9c976ff" visible="True" isExpanded="true" title="Version History">
<HelpKeywords>
<HelpKeyword index="K" term="history" />
<HelpKeyword index="K" term="version history" />
</HelpKeywords>
<Topic id="d1d9a1d2-7495-457e-9095-880ab00515a3" visible="True" isSelected="true" title="Version 2023.1.2.0">
<HelpKeywords>
<HelpKeyword index="K" term="versions, 2023.1.2.0" />
</HelpKeywords>
</Topic>
<Topic id="3ebeed58-ecb5-475f-93c1-c9e0098ac5a0" visible="True" title="Version 2021.11.23.0">
<HelpKeywords>
<HelpKeyword index="K" term="versions, 2021.11.23.0" />
Expand Down
5 changes: 3 additions & 2 deletions Doc/EWSoftwarePDI.shfbproj
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
<FrameworkVersion>.NET Framework 4.0</FrameworkVersion>
<HelpTitle>EWSoftware.PDI Namespace Documentation</HelpTitle>
<CopyrightHref>https://github.com/EWSoftware/PDI</CopyrightHref>
<CopyrightText>[v{%40HelpFileVersion}] Copyright \xA9 2003-2021, Eric Woodruff, All Rights Reserved</CopyrightText>
<CopyrightText>[v{%40HelpFileVersion}] Copyright \xA9 2003-2023, Eric Woodruff, All Rights Reserved</CopyrightText>
<FeedbackEMailAddress>Eric%40EWoodruff.us</FeedbackEMailAddress>
<PresentationStyle>Default2022</PresentationStyle>
<SyntaxFilters>Standard</SyntaxFilters>
Expand All @@ -49,7 +49,7 @@
<NamespaceSummaryItem name="EWSoftware.PDI.Web.Design" isDocumented="True">Personal Data Interchange ASP.NET web server control designers developed by Eric Woodruff.</NamespaceSummaryItem>
<NamespaceSummaryItem name="EWSoftware.PDI.Windows.Forms" isDocumented="True">Personal Data Interchange Windows Forms controls developed by Eric Woodruff.</NamespaceSummaryItem>
</NamespaceSummaries>
<HelpFileVersion>2021.11.23.0</HelpFileVersion>
<HelpFileVersion>2022.1.2.0</HelpFileVersion>
<ApiFilter />
<PlugInConfigurations>
<PlugInConfig id="Output Deployment" enabled="True">
Expand Down Expand Up @@ -194,6 +194,7 @@
<None Include="Content\VersionHistory\v2020.11.25.0.aml" />
<None Include="Content\VersionHistory\v2020.7.24.0.aml" />
<None Include="Content\VersionHistory\v2021.11.23.0.aml" />
<None Include="Content\VersionHistory\v2023.1.2.0.aml" />
<None Include="Content\Welcome.aml" />
<None Include="Content\VersionHistory\v2.0.0.2.aml" />
<None Include="Content\VersionHistory\v2.0.0.0.aml" />
Expand Down
6 changes: 3 additions & 3 deletions MasterBuild.bat
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ IF EXIST "%ProgramFiles(x86)%\Microsoft Visual Studio\2017\Enterprise\MSBuild\15
IF EXIST "%ProgramFiles(x86)%\Microsoft Visual Studio\2019\Community\MSBuild\Current" SET "MSBUILD=%ProgramFiles(x86)%\Microsoft Visual Studio\2019\Community\MSBuild\Current\bin\MSBuild.exe"
IF EXIST "%ProgramFiles(x86)%\Microsoft Visual Studio\2019\Professional\MSBuild\Current" SET "MSBUILD=%ProgramFiles(x86)%\Microsoft Visual Studio\2019\Professional\MSBuild\Current\bin\MSBuild.exe"
IF EXIST "%ProgramFiles(x86)%\Microsoft Visual Studio\2019\Enterprise\MSBuild\Current" SET "MSBUILD=%ProgramFiles(x86)%\Microsoft Visual Studio\2019\Enterprise\MSBuild\Current\bin\MSBuild.exe"
IF EXIST "%ProgramFiles(x86)%\Microsoft Visual Studio\2022\Community\MSBuild\Current" SET "MSBUILD=%ProgramFiles(x86)%\Microsoft Visual Studio\2022\Community\MSBuild\Current\bin\MSBuild.exe"
IF EXIST "%ProgramFiles(x86)%\Microsoft Visual Studio\2022\Professional\MSBuild\Current" SET "MSBUILD=%ProgramFiles(x86)%\Microsoft Visual Studio\2022\Professional\MSBuild\Current\bin\MSBuild.exe"
IF EXIST "%ProgramFiles(x86)%\Microsoft Visual Studio\202\Enterprise\MSBuild\Current" SET "MSBUILD=%ProgramFiles(x86)%\Microsoft Visual Studio\2022\Enterprise\MSBuild\Current\bin\MSBuild.exe"
IF EXIST "%ProgramFiles%\Microsoft Visual Studio\2022\Community\MSBuild\Current" SET "MSBUILD=%ProgramFiles%\Microsoft Visual Studio\2022\Community\MSBuild\Current\bin\MSBuild.exe"
IF EXIST "%ProgramFiles%\Microsoft Visual Studio\2022\Professional\MSBuild\Current" SET "MSBUILD=%ProgramFiles%\Microsoft Visual Studio\2022\Professional\MSBuild\Current\bin\MSBuild.exe"
IF EXIST "%ProgramFiles%\Microsoft Visual Studio\2022\Enterprise\MSBuild\Current" SET "MSBUILD=%ProgramFiles%\Microsoft Visual Studio\2022\Enterprise\MSBuild\Current\bin\MSBuild.exe"

"%MSBUILD%" /nologo /v:m /m Source\EWSPDI.sln /t:Clean;Build "/p:Configuration=Release;Platform=Any CPU"

Expand Down
18 changes: 12 additions & 6 deletions Source/.editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,12 @@ dotnet_style_explicit_tuple_names = true : error
dotnet_style_null_propagation = true : suggestion
dotnet_style_object_initializer = true : suggestion

# CA1303: Do not pass literals as localized parameters
dotnet_diagnostic.CA1303.severity = none

# IDE1006: Naming Styles
dotnet_diagnostic.IDE1006.severity = none

# CSharp code style settings
[*.cs]
csharp_style_var_elsewhere = false : none
Expand Down Expand Up @@ -94,9 +100,6 @@ csharp_space_between_method_declaration_empty_parameter_list_parentheses = false
csharp_space_between_method_declaration_name_and_open_parenthesis = false
csharp_space_between_method_declaration_parameter_list_parentheses = false

# CA1303: Do not pass literals as localized parameters
dotnet_diagnostic.CA1303.severity = none

# IDE0010: Add missing cases
dotnet_diagnostic.IDE0010.severity = none

Expand All @@ -118,9 +121,6 @@ dotnet_diagnostic.IDE0055.severity = none
# IDE0058: Expression value is never used
dotnet_diagnostic.IDE0058.severity = none

# IDE1006: Naming Styles
dotnet_diagnostic.IDE1006.severity = none

# These are disabled as we're still targeting .NET Framework as well and I don't want a lot of conditional code
# to suppress these.
# IDE0056: Use index operator
Expand All @@ -131,3 +131,9 @@ dotnet_diagnostic.IDE0057.severity = none

# IDE0063: Use simple 'using' statement
dotnet_diagnostic.IDE0063.severity = none

# IDE0066: Convert switch statement to expression
dotnet_diagnostic.IDE0066.severity = none

# IDE0090: Use 'new(...)'
dotnet_diagnostic.IDE0090.severity = none
21 changes: 10 additions & 11 deletions Source/CSharpDemos.sln
Original file line number Diff line number Diff line change
@@ -1,19 +1,16 @@
Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 15
VisualStudioVersion = 15.0.27004.2002
# Visual Studio Version 17
VisualStudioVersion = 17.4.33205.214
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CalendarBrowser", "CSharpDemos\CalendarBrowser\CalendarBrowser.csproj", "{20487237-F96A-4725-A82D-96FD26AF9DFE}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "CalendarBrowser", "CSharpDemos\CalendarBrowser\CalendarBrowser.csproj", "{20487237-F96A-4725-A82D-96FD26AF9DFE}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "PDIWinFormsTest", "CSharpDemos\PDIWinFormsTest\PDIWinFormsTest.csproj", "{011CC2DB-A5AE-4788-AF84-C4C1A8CDF10A}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "vCardBrowser", "CSharpDemos\vCardBrowser\vCardBrowser.csproj", "{AC9020EB-63D3-4515-A868-8D290356FBE5}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "vCardBrowser", "CSharpDemos\vCardBrowser\vCardBrowser.csproj", "{AC9020EB-63D3-4515-A868-8D290356FBE5}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{D3E23A2C-E571-4DF2-BCA1-172B2C994300}"
ProjectSection(SolutionItems) = preProject
.editorconfig = .editorconfig
Common.vsspell = Common.vsspell
CSharpDemos.sln.vsspell = CSharpDemos.sln.vsspell
EWSPDIDemos.ruleset = EWSPDIDemos.ruleset
EndProjectSection
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "EWSoftware.PDI", "EWSPDI\EWSoftware.PDI.csproj", "{024821DE-3508-476A-97E7-441334A1B2DF}"
Expand All @@ -28,6 +25,8 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "PDIParserTest", "CSharpDemo
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "RFC2445RecurTest", "CSharpDemos\RFC2445RecurTest\RFC2445RecurTest.csproj", "{E0D46484-AAAE-41A1-85A7-9903B3DACB28}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "PDIWinFormsTest", "CSharpDemos\PDIWinFormsTest\PDIWinFormsTest.csproj", "{969B43B1-5E6E-4C96-AE49-36A4D88119D8}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand All @@ -38,10 +37,6 @@ Global
{20487237-F96A-4725-A82D-96FD26AF9DFE}.Debug|Any CPU.Build.0 = Debug|Any CPU
{20487237-F96A-4725-A82D-96FD26AF9DFE}.Release|Any CPU.ActiveCfg = Release|Any CPU
{20487237-F96A-4725-A82D-96FD26AF9DFE}.Release|Any CPU.Build.0 = Release|Any CPU
{011CC2DB-A5AE-4788-AF84-C4C1A8CDF10A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{011CC2DB-A5AE-4788-AF84-C4C1A8CDF10A}.Debug|Any CPU.Build.0 = Debug|Any CPU
{011CC2DB-A5AE-4788-AF84-C4C1A8CDF10A}.Release|Any CPU.ActiveCfg = Release|Any CPU
{011CC2DB-A5AE-4788-AF84-C4C1A8CDF10A}.Release|Any CPU.Build.0 = Release|Any CPU
{AC9020EB-63D3-4515-A868-8D290356FBE5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{AC9020EB-63D3-4515-A868-8D290356FBE5}.Debug|Any CPU.Build.0 = Debug|Any CPU
{AC9020EB-63D3-4515-A868-8D290356FBE5}.Release|Any CPU.ActiveCfg = Release|Any CPU
Expand Down Expand Up @@ -70,6 +65,10 @@ Global
{E0D46484-AAAE-41A1-85A7-9903B3DACB28}.Debug|Any CPU.Build.0 = Debug|Any CPU
{E0D46484-AAAE-41A1-85A7-9903B3DACB28}.Release|Any CPU.ActiveCfg = Release|Any CPU
{E0D46484-AAAE-41A1-85A7-9903B3DACB28}.Release|Any CPU.Build.0 = Release|Any CPU
{969B43B1-5E6E-4C96-AE49-36A4D88119D8}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{969B43B1-5E6E-4C96-AE49-36A4D88119D8}.Debug|Any CPU.Build.0 = Debug|Any CPU
{969B43B1-5E6E-4C96-AE49-36A4D88119D8}.Release|Any CPU.ActiveCfg = Release|Any CPU
{969B43B1-5E6E-4C96-AE49-36A4D88119D8}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down
21 changes: 10 additions & 11 deletions Source/CSharpDemos/CalendarBrowser/AttachmentsControl.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,8 @@
// System : EWSoftware PDI Demonstration Applications
// File : AttachmentsControl.cs
// Author : Eric Woodruff (Eric@EWoodruff.us)
// Updated : 11/24/2018
// Note : Copyright 2004-2018, Eric Woodruff, All rights reserved
// Compiler: Visual C#
// Updated : 01/02/2023
// Note : Copyright 2004-2023, Eric Woodruff, All rights reserved
//
// This is used to edit a calendar object's attachment properties
//
Expand Down Expand Up @@ -82,9 +81,9 @@ public void SetValues(AttachPropertyCollection attachments)
foreach(AttachProperty a in attach)
{
if(a.ValueLocation == ValLocValue.Binary)
desc = String.Format("Inline - {0}", a.FormatType);
desc = $"Inline - {a.FormatType}";
else
desc = String.Format("External - {0}, {1}", a.FormatType, a.Value);
desc = $"External - {a.FormatType}, {a.Value}";

lbAttachments.Items.Add(desc);
}
Expand All @@ -103,8 +102,8 @@ public void SetValues(AttachPropertyCollection attachments)
/// <param name="attachments">The attachments collection to update</param>
public void GetValues(AttachPropertyCollection attachments)
{
attachments.Clear();
attachments.CloneRange(attach);
attachments?.Clear();
attachments?.CloneRange(attach);
}
#endregion

Expand Down Expand Up @@ -177,7 +176,7 @@ private void btnAdd_Click(object sender, EventArgs e)
{
a.ValueLocation = ValLocValue.Uri;
a.Value = txtFilename.Text;
desc = String.Format("External - {0}, {1}", a.FormatType, a.Value);
desc = $"External - {a.FormatType}, {a.Value}";
}
else
{
Expand All @@ -190,15 +189,15 @@ private void btnAdd_Click(object sender, EventArgs e)
a.SetAttachmentBytes(byData);
}

desc = String.Format("Inline - {0}", a.FormatType);
desc = $"Inline - {a.FormatType}";
}

attach.Add(a);
lbAttachments.Items.Add(desc);
}
catch(Exception ex)
{
string error = String.Format("Unable to add attachment:\n{0}", ex.Message);
string error = $"Unable to add attachment:\n{ex.Message}";

if(ex.InnerException != null)
{
Expand Down Expand Up @@ -278,7 +277,7 @@ private void btnDetach_Click(object sender, EventArgs e)
}
catch(Exception ex)
{
string error = String.Format("Unable to save attachment:\n{0}", ex.Message);
string error = $"Unable to save attachment:\n{ex.Message}";

if(ex.InnerException != null)
{
Expand Down

0 comments on commit cb77c0b

Please sign in to comment.