From dd07406b85b2d162a1c4d42a2dd6867ca4ccf579 Mon Sep 17 00:00:00 2001 From: ​ Date: Thu, 1 Jan 1970 00:00:00 +0000 Subject: string handling --- .../stringhandling.metadata.v7.bin | Bin 0 -> 178130 bytes .../stringhandling.projects.v7.bin | Bin 0 -> 490581 bytes .../StringHandling/DesignTimeBuild/.dtbcache.v2 | Bin 0 -> 74756 bytes .../0e2386e1-da9f-4eea-bac9-78e6bc71d398.vsidx | Bin 0 -> 25912 bytes .../408b56a4-68bb-49a5-aa6d-b55924b131d7.vsidx | Bin 0 -> 28833 bytes .../e2eaebbc-7b85-4f82-96dc-42e69937674e.vsidx | Bin 0 -> 5824 bytes .../.vs/StringHandling/v17/.futdcache.v2 | Bin 0 -> 300 bytes string_handling/.vs/StringHandling/v17/.suo | Bin 0 -> 30208 bytes string_handling/StringHandling.sln | 25 ++++ string_handling/StringHandling/Program.cs | 23 ++++ .../StringHandling/StringHandling.csproj | 9 ++ .../StringHandling/StringHandling.csproj.user | 8 ++ .../Debug/netcoreapp3.1/StringHandling.deps.json | 23 ++++ .../bin/Debug/netcoreapp3.1/StringHandling.dll | Bin 0 -> 9728 bytes .../bin/Debug/netcoreapp3.1/StringHandling.exe | Bin 0 -> 158208 bytes .../bin/Debug/netcoreapp3.1/StringHandling.pdb | Bin 0 -> 12480 bytes .../StringHandling.runtimeconfig.dev.json | 8 ++ .../StringHandling.runtimeconfig.json | 9 ++ string_handling/StringHandling/frmMain.Designer.cs | 132 +++++++++++++++++++++ string_handling/StringHandling/frmMain.cs | 89 ++++++++++++++ string_handling/StringHandling/frmMain.resx | 120 +++++++++++++++++++ .../.NETCoreApp,Version=v3.1.AssemblyAttributes.cs | 4 + .../netcoreapp3.1/StringHandling.AssemblyInfo.cs | 23 ++++ .../StringHandling.AssemblyInfoInputs.cache | 1 + ...dling.GeneratedMSBuildEditorConfig.editorconfig | 11 ++ .../netcoreapp3.1/StringHandling.assets.cache | Bin 0 -> 151 bytes .../StringHandling.csproj.BuildWithSkipAnalyzers | 0 .../StringHandling.csproj.CoreCompileInputs.cache | 1 + .../StringHandling.csproj.FileListAbsolute.txt | 30 +++++ .../StringHandling.csproj.GenerateResource.cache | Bin 0 -> 100 bytes .../StringHandling.designer.deps.json | 11 ++ .../StringHandling.designer.runtimeconfig.json | 16 +++ .../obj/Debug/netcoreapp3.1/StringHandling.dll | Bin 0 -> 9728 bytes .../netcoreapp3.1/StringHandling.frmMain.resources | Bin 0 -> 180 bytes .../StringHandling.genruntimeconfig.cache | 1 + .../obj/Debug/netcoreapp3.1/StringHandling.pdb | Bin 0 -> 12480 bytes .../obj/Debug/netcoreapp3.1/apphost.exe | Bin 0 -> 158208 bytes .../obj/StringHandling.csproj.nuget.dgspec.json | 66 +++++++++++ .../obj/StringHandling.csproj.nuget.g.props | 15 +++ .../obj/StringHandling.csproj.nuget.g.targets | 2 + .../StringHandling/obj/project.assets.json | 71 +++++++++++ .../StringHandling/obj/project.nuget.cache | 8 ++ 42 files changed, 706 insertions(+) create mode 100644 string_handling/.vs/ProjectEvaluation/stringhandling.metadata.v7.bin create mode 100644 string_handling/.vs/ProjectEvaluation/stringhandling.projects.v7.bin create mode 100644 string_handling/.vs/StringHandling/DesignTimeBuild/.dtbcache.v2 create mode 100644 string_handling/.vs/StringHandling/FileContentIndex/0e2386e1-da9f-4eea-bac9-78e6bc71d398.vsidx create mode 100644 string_handling/.vs/StringHandling/FileContentIndex/408b56a4-68bb-49a5-aa6d-b55924b131d7.vsidx create mode 100644 string_handling/.vs/StringHandling/FileContentIndex/e2eaebbc-7b85-4f82-96dc-42e69937674e.vsidx create mode 100644 string_handling/.vs/StringHandling/v17/.futdcache.v2 create mode 100644 string_handling/.vs/StringHandling/v17/.suo create mode 100644 string_handling/StringHandling.sln create mode 100644 string_handling/StringHandling/Program.cs create mode 100644 string_handling/StringHandling/StringHandling.csproj create mode 100644 string_handling/StringHandling/StringHandling.csproj.user create mode 100644 string_handling/StringHandling/bin/Debug/netcoreapp3.1/StringHandling.deps.json create mode 100644 string_handling/StringHandling/bin/Debug/netcoreapp3.1/StringHandling.dll create mode 100644 string_handling/StringHandling/bin/Debug/netcoreapp3.1/StringHandling.exe create mode 100644 string_handling/StringHandling/bin/Debug/netcoreapp3.1/StringHandling.pdb create mode 100644 string_handling/StringHandling/bin/Debug/netcoreapp3.1/StringHandling.runtimeconfig.dev.json create mode 100644 string_handling/StringHandling/bin/Debug/netcoreapp3.1/StringHandling.runtimeconfig.json create mode 100644 string_handling/StringHandling/frmMain.Designer.cs create mode 100644 string_handling/StringHandling/frmMain.cs create mode 100644 string_handling/StringHandling/frmMain.resx create mode 100644 string_handling/StringHandling/obj/Debug/netcoreapp3.1/.NETCoreApp,Version=v3.1.AssemblyAttributes.cs create mode 100644 string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.AssemblyInfo.cs create mode 100644 string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.AssemblyInfoInputs.cache create mode 100644 string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.GeneratedMSBuildEditorConfig.editorconfig create mode 100644 string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.assets.cache create mode 100644 string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.csproj.BuildWithSkipAnalyzers create mode 100644 string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.csproj.CoreCompileInputs.cache create mode 100644 string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.csproj.FileListAbsolute.txt create mode 100644 string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.csproj.GenerateResource.cache create mode 100644 string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.designer.deps.json create mode 100644 string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.designer.runtimeconfig.json create mode 100644 string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.dll create mode 100644 string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.frmMain.resources create mode 100644 string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.genruntimeconfig.cache create mode 100644 string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.pdb create mode 100644 string_handling/StringHandling/obj/Debug/netcoreapp3.1/apphost.exe create mode 100644 string_handling/StringHandling/obj/StringHandling.csproj.nuget.dgspec.json create mode 100644 string_handling/StringHandling/obj/StringHandling.csproj.nuget.g.props create mode 100644 string_handling/StringHandling/obj/StringHandling.csproj.nuget.g.targets create mode 100644 string_handling/StringHandling/obj/project.assets.json create mode 100644 string_handling/StringHandling/obj/project.nuget.cache diff --git a/string_handling/.vs/ProjectEvaluation/stringhandling.metadata.v7.bin b/string_handling/.vs/ProjectEvaluation/stringhandling.metadata.v7.bin new file mode 100644 index 0000000..0630f9d Binary files /dev/null and b/string_handling/.vs/ProjectEvaluation/stringhandling.metadata.v7.bin differ diff --git a/string_handling/.vs/ProjectEvaluation/stringhandling.projects.v7.bin b/string_handling/.vs/ProjectEvaluation/stringhandling.projects.v7.bin new file mode 100644 index 0000000..82c9cb8 Binary files /dev/null and b/string_handling/.vs/ProjectEvaluation/stringhandling.projects.v7.bin differ diff --git a/string_handling/.vs/StringHandling/DesignTimeBuild/.dtbcache.v2 b/string_handling/.vs/StringHandling/DesignTimeBuild/.dtbcache.v2 new file mode 100644 index 0000000..2b3a64f Binary files /dev/null and b/string_handling/.vs/StringHandling/DesignTimeBuild/.dtbcache.v2 differ diff --git a/string_handling/.vs/StringHandling/FileContentIndex/0e2386e1-da9f-4eea-bac9-78e6bc71d398.vsidx b/string_handling/.vs/StringHandling/FileContentIndex/0e2386e1-da9f-4eea-bac9-78e6bc71d398.vsidx new file mode 100644 index 0000000..3fa36c6 Binary files /dev/null and b/string_handling/.vs/StringHandling/FileContentIndex/0e2386e1-da9f-4eea-bac9-78e6bc71d398.vsidx differ diff --git a/string_handling/.vs/StringHandling/FileContentIndex/408b56a4-68bb-49a5-aa6d-b55924b131d7.vsidx b/string_handling/.vs/StringHandling/FileContentIndex/408b56a4-68bb-49a5-aa6d-b55924b131d7.vsidx new file mode 100644 index 0000000..1c79dbc Binary files /dev/null and b/string_handling/.vs/StringHandling/FileContentIndex/408b56a4-68bb-49a5-aa6d-b55924b131d7.vsidx differ diff --git a/string_handling/.vs/StringHandling/FileContentIndex/e2eaebbc-7b85-4f82-96dc-42e69937674e.vsidx b/string_handling/.vs/StringHandling/FileContentIndex/e2eaebbc-7b85-4f82-96dc-42e69937674e.vsidx new file mode 100644 index 0000000..93b1de0 Binary files /dev/null and b/string_handling/.vs/StringHandling/FileContentIndex/e2eaebbc-7b85-4f82-96dc-42e69937674e.vsidx differ diff --git a/string_handling/.vs/StringHandling/v17/.futdcache.v2 b/string_handling/.vs/StringHandling/v17/.futdcache.v2 new file mode 100644 index 0000000..a1a7295 Binary files /dev/null and b/string_handling/.vs/StringHandling/v17/.futdcache.v2 differ diff --git a/string_handling/.vs/StringHandling/v17/.suo b/string_handling/.vs/StringHandling/v17/.suo new file mode 100644 index 0000000..6cbadc8 Binary files /dev/null and b/string_handling/.vs/StringHandling/v17/.suo differ diff --git a/string_handling/StringHandling.sln b/string_handling/StringHandling.sln new file mode 100644 index 0000000..87fda53 --- /dev/null +++ b/string_handling/StringHandling.sln @@ -0,0 +1,25 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio Version 16 +VisualStudioVersion = 16.0.30413.136 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "StringHandling", "StringHandling\StringHandling.csproj", "{DC152C2D-F31A-4C38-BFE6-30A5230C2EF4}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Release|Any CPU = Release|Any CPU + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {DC152C2D-F31A-4C38-BFE6-30A5230C2EF4}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {DC152C2D-F31A-4C38-BFE6-30A5230C2EF4}.Debug|Any CPU.Build.0 = Debug|Any CPU + {DC152C2D-F31A-4C38-BFE6-30A5230C2EF4}.Release|Any CPU.ActiveCfg = Release|Any CPU + {DC152C2D-F31A-4C38-BFE6-30A5230C2EF4}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {534B9418-EE5C-4FDE-A283-1C024E47935A} + EndGlobalSection +EndGlobal diff --git a/string_handling/StringHandling/Program.cs b/string_handling/StringHandling/Program.cs new file mode 100644 index 0000000..14abfd3 --- /dev/null +++ b/string_handling/StringHandling/Program.cs @@ -0,0 +1,23 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; +using System.Windows.Forms; + +namespace StringHandling +{ + static class Program + { + /// + /// The main entry point for the application. + /// + [STAThread] + static void Main() + { + Application.SetHighDpiMode(HighDpiMode.SystemAware); + Application.EnableVisualStyles(); + Application.SetCompatibleTextRenderingDefault(false); + Application.Run(new frmMain()); + } + } +} diff --git a/string_handling/StringHandling/StringHandling.csproj b/string_handling/StringHandling/StringHandling.csproj new file mode 100644 index 0000000..7b05c62 --- /dev/null +++ b/string_handling/StringHandling/StringHandling.csproj @@ -0,0 +1,9 @@ + + + + WinExe + netcoreapp3.1 + true + + + \ No newline at end of file diff --git a/string_handling/StringHandling/StringHandling.csproj.user b/string_handling/StringHandling/StringHandling.csproj.user new file mode 100644 index 0000000..a869d18 --- /dev/null +++ b/string_handling/StringHandling/StringHandling.csproj.user @@ -0,0 +1,8 @@ + + + + + Form + + + \ No newline at end of file diff --git a/string_handling/StringHandling/bin/Debug/netcoreapp3.1/StringHandling.deps.json b/string_handling/StringHandling/bin/Debug/netcoreapp3.1/StringHandling.deps.json new file mode 100644 index 0000000..f38d702 --- /dev/null +++ b/string_handling/StringHandling/bin/Debug/netcoreapp3.1/StringHandling.deps.json @@ -0,0 +1,23 @@ +{ + "runtimeTarget": { + "name": ".NETCoreApp,Version=v3.1", + "signature": "" + }, + "compilationOptions": {}, + "targets": { + ".NETCoreApp,Version=v3.1": { + "StringHandling/1.0.0": { + "runtime": { + "StringHandling.dll": {} + } + } + } + }, + "libraries": { + "StringHandling/1.0.0": { + "type": "project", + "serviceable": false, + "sha512": "" + } + } +} \ No newline at end of file diff --git a/string_handling/StringHandling/bin/Debug/netcoreapp3.1/StringHandling.dll b/string_handling/StringHandling/bin/Debug/netcoreapp3.1/StringHandling.dll new file mode 100644 index 0000000..70d0f6b Binary files /dev/null and b/string_handling/StringHandling/bin/Debug/netcoreapp3.1/StringHandling.dll differ diff --git a/string_handling/StringHandling/bin/Debug/netcoreapp3.1/StringHandling.exe b/string_handling/StringHandling/bin/Debug/netcoreapp3.1/StringHandling.exe new file mode 100644 index 0000000..dc74048 Binary files /dev/null and b/string_handling/StringHandling/bin/Debug/netcoreapp3.1/StringHandling.exe differ diff --git a/string_handling/StringHandling/bin/Debug/netcoreapp3.1/StringHandling.pdb b/string_handling/StringHandling/bin/Debug/netcoreapp3.1/StringHandling.pdb new file mode 100644 index 0000000..7b25e18 Binary files /dev/null and b/string_handling/StringHandling/bin/Debug/netcoreapp3.1/StringHandling.pdb differ diff --git a/string_handling/StringHandling/bin/Debug/netcoreapp3.1/StringHandling.runtimeconfig.dev.json b/string_handling/StringHandling/bin/Debug/netcoreapp3.1/StringHandling.runtimeconfig.dev.json new file mode 100644 index 0000000..214bf78 --- /dev/null +++ b/string_handling/StringHandling/bin/Debug/netcoreapp3.1/StringHandling.runtimeconfig.dev.json @@ -0,0 +1,8 @@ +{ + "runtimeOptions": { + "additionalProbingPaths": [ + "C:\\Users\\User\\.dotnet\\store\\|arch|\\|tfm|", + "C:\\Users\\User\\.nuget\\packages" + ] + } +} \ No newline at end of file diff --git a/string_handling/StringHandling/bin/Debug/netcoreapp3.1/StringHandling.runtimeconfig.json b/string_handling/StringHandling/bin/Debug/netcoreapp3.1/StringHandling.runtimeconfig.json new file mode 100644 index 0000000..9b3a644 --- /dev/null +++ b/string_handling/StringHandling/bin/Debug/netcoreapp3.1/StringHandling.runtimeconfig.json @@ -0,0 +1,9 @@ +{ + "runtimeOptions": { + "tfm": "netcoreapp3.1", + "framework": { + "name": "Microsoft.WindowsDesktop.App", + "version": "3.1.0" + } + } +} \ No newline at end of file diff --git a/string_handling/StringHandling/frmMain.Designer.cs b/string_handling/StringHandling/frmMain.Designer.cs new file mode 100644 index 0000000..dedeeb8 --- /dev/null +++ b/string_handling/StringHandling/frmMain.Designer.cs @@ -0,0 +1,132 @@ +namespace StringHandling +{ + partial class frmMain + { + /// + /// Required designer variable. + /// + private System.ComponentModel.IContainer components = null; + + /// + /// Clean up any resources being used. + /// + /// true if managed resources should be disposed; otherwise, false. + protected override void Dispose(bool disposing) + { + if (disposing && (components != null)) + { + components.Dispose(); + } + base.Dispose(disposing); + } + + #region Windows Form Designer generated code + + /// + /// Required method for Designer support - do not modify + /// the contents of this method with the code editor. + /// + private void InitializeComponent() + { + this.btnExit = new System.Windows.Forms.Button(); + this.btnEditPhoneNumber = new System.Windows.Forms.Button(); + this.btnParseName = new System.Windows.Forms.Button(); + this.txtPhoneNumber = new System.Windows.Forms.TextBox(); + this.txtFullName = new System.Windows.Forms.TextBox(); + this.label2 = new System.Windows.Forms.Label(); + this.label1 = new System.Windows.Forms.Label(); + this.SuspendLayout(); + // + // btnExit + // + this.btnExit.Location = new System.Drawing.Point(292, 78); + this.btnExit.Name = "btnExit"; + this.btnExit.Size = new System.Drawing.Size(63, 20); + this.btnExit.TabIndex = 11; + this.btnExit.Text = "E&xit"; + this.btnExit.Click += new System.EventHandler(this.btnExit_Click); + // + // btnEditPhoneNumber + // + this.btnEditPhoneNumber.Location = new System.Drawing.Point(292, 44); + this.btnEditPhoneNumber.Name = "btnEditPhoneNumber"; + this.btnEditPhoneNumber.Size = new System.Drawing.Size(154, 19); + this.btnEditPhoneNumber.TabIndex = 10; + this.btnEditPhoneNumber.Text = "Edit Phone Number"; + this.btnEditPhoneNumber.Click += new System.EventHandler(this.btnEditPhoneNumber_Click); + // + // btnParseName + // + this.btnParseName.Location = new System.Drawing.Point(292, 9); + this.btnParseName.Name = "btnParseName"; + this.btnParseName.Size = new System.Drawing.Size(154, 20); + this.btnParseName.TabIndex = 8; + this.btnParseName.Text = "Parse Name"; + this.btnParseName.Click += new System.EventHandler(this.btnParseName_Click); + // + // txtPhoneNumber + // + this.txtPhoneNumber.Location = new System.Drawing.Point(132, 44); + this.txtPhoneNumber.Name = "txtPhoneNumber"; + this.txtPhoneNumber.Size = new System.Drawing.Size(87, 20); + this.txtPhoneNumber.TabIndex = 9; + this.txtPhoneNumber.Text = "(559) 440-9071"; + // + // txtFullName + // + this.txtFullName.Location = new System.Drawing.Point(132, 9); + this.txtFullName.Name = "txtFullName"; + this.txtFullName.Size = new System.Drawing.Size(147, 20); + this.txtFullName.TabIndex = 5; + this.txtFullName.Text = "joel ray murach"; + // + // label2 + // + this.label2.Location = new System.Drawing.Point(12, 44); + this.label2.Name = "label2"; + this.label2.Size = new System.Drawing.Size(114, 19); + this.label2.TabIndex = 7; + this.label2.Text = "Enter phone number:"; + this.label2.TextAlign = System.Drawing.ContentAlignment.MiddleLeft; + // + // label1 + // + this.label1.Location = new System.Drawing.Point(12, 9); + this.label1.Name = "label1"; + this.label1.Size = new System.Drawing.Size(114, 20); + this.label1.TabIndex = 6; + this.label1.Text = "Enter full name:"; + this.label1.TextAlign = System.Drawing.ContentAlignment.MiddleLeft; + // + // Form1 + // + this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); + this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; + this.CancelButton = this.btnExit; + this.ClientSize = new System.Drawing.Size(468, 108); + this.Controls.Add(this.btnExit); + this.Controls.Add(this.btnEditPhoneNumber); + this.Controls.Add(this.btnParseName); + this.Controls.Add(this.txtPhoneNumber); + this.Controls.Add(this.txtFullName); + this.Controls.Add(this.label2); + this.Controls.Add(this.label1); + this.Name = "Form1"; + this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen; + this.Text = "String Handling"; + this.ResumeLayout(false); + this.PerformLayout(); + } + + #endregion + + private System.Windows.Forms.Button btnExit; + private System.Windows.Forms.Button btnEditPhoneNumber; + private System.Windows.Forms.Button btnParseName; + private System.Windows.Forms.TextBox txtPhoneNumber; + private System.Windows.Forms.TextBox txtFullName; + private System.Windows.Forms.Label label2; + private System.Windows.Forms.Label label1; + } +} + diff --git a/string_handling/StringHandling/frmMain.cs b/string_handling/StringHandling/frmMain.cs new file mode 100644 index 0000000..3db9fec --- /dev/null +++ b/string_handling/StringHandling/frmMain.cs @@ -0,0 +1,89 @@ +#nullable enable +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Data; +using System.Drawing; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows.Forms; + +namespace StringHandling +{ + public partial class frmMain : Form + { + public frmMain() + { + InitializeComponent(); + } + + private void btnParseName_Click(object sender, System.EventArgs e) + { + // DONE: Add code to parse name + string fName = ""; + string? mName = null; + string lName = ""; + + string name = txtFullName.Text.Trim(); + string[] names = name.ToLower().Split(' '); + + if (names.Length == 2) { + fName = names[0]; + lName = names[1]; + } + else if (names.Length == 3) { + fName = names[0]; + mName = names[1]; + lName = names[2]; + } + else { + MessageBox.Show("You need to enter a full name " + + "consisting of 2 or optionally 3 words", + "Error"); + return; + } + + string msg = "First name:\t" + ToInitialCap(fName) + + "\n\nMiddle Name:"; + if (mName != null) + msg += "\t" + ToInitialCap(mName); + msg += "\n\nLast name:\t" + ToInitialCap(lName); + + MessageBox.Show(msg, "Parse Name"); + } + + private void btnEditPhoneNumber_Click(object sender, System.EventArgs e) + { + // DONE: Add code to edit the phone number + string phone = txtPhoneNumber.Text.Trim(); + + string digits = ""; + foreach (char i in phone) + if (i >= '0' && i <= '9') + digits += i; + + string standard = digits; + standard = standard.Insert(3, "-"); + standard = standard.Insert(7, "-"); + + MessageBox.Show("Entered:\t\t" + + phone + "\n\nDigits only:\t" + + digits + "\n\nStandard format:\t" + + standard, "Edit Phone Number"); + } + + // DONE: Add ToInitialCap method here + private string ToInitialCap(string s) + { + return s[0].ToString().ToUpper() + + s.Remove(0, 1); + } + + private void btnExit_Click(object sender, System.EventArgs e) + { + this.Close(); + } + + } +} diff --git a/string_handling/StringHandling/frmMain.resx b/string_handling/StringHandling/frmMain.resx new file mode 100644 index 0000000..29dcb1b --- /dev/null +++ b/string_handling/StringHandling/frmMain.resx @@ -0,0 +1,120 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + \ No newline at end of file diff --git a/string_handling/StringHandling/obj/Debug/netcoreapp3.1/.NETCoreApp,Version=v3.1.AssemblyAttributes.cs b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/.NETCoreApp,Version=v3.1.AssemblyAttributes.cs new file mode 100644 index 0000000..3364fdf --- /dev/null +++ b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/.NETCoreApp,Version=v3.1.AssemblyAttributes.cs @@ -0,0 +1,4 @@ +// +using System; +using System.Reflection; +[assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETCoreApp,Version=v3.1", FrameworkDisplayName = ".NET Core 3.1")] diff --git a/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.AssemblyInfo.cs b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.AssemblyInfo.cs new file mode 100644 index 0000000..0ec3eb4 --- /dev/null +++ b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.AssemblyInfo.cs @@ -0,0 +1,23 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Runtime Version:4.0.30319.42000 +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + +using System; +using System.Reflection; + +[assembly: System.Reflection.AssemblyCompanyAttribute("StringHandling")] +[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")] +[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")] +[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0")] +[assembly: System.Reflection.AssemblyProductAttribute("StringHandling")] +[assembly: System.Reflection.AssemblyTitleAttribute("StringHandling")] +[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")] + +// Generated by the MSBuild WriteCodeFragment class. + diff --git a/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.AssemblyInfoInputs.cache b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.AssemblyInfoInputs.cache new file mode 100644 index 0000000..050be0e --- /dev/null +++ b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.AssemblyInfoInputs.cache @@ -0,0 +1 @@ +894ce39085c952804fe56d4bb9d8eba4664e7ad079b730dcd624fa1400e8a3bc diff --git a/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.GeneratedMSBuildEditorConfig.editorconfig b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.GeneratedMSBuildEditorConfig.editorconfig new file mode 100644 index 0000000..ebbf587 --- /dev/null +++ b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.GeneratedMSBuildEditorConfig.editorconfig @@ -0,0 +1,11 @@ +is_global = true +build_property.ApplicationManifest = +build_property.StartupObject = +build_property.ApplicationDefaultFont = +build_property.ApplicationHighDpiMode = +build_property.ApplicationUseCompatibleTextRendering = +build_property.ApplicationVisualStyles = +build_property.RootNamespace = StringHandling +build_property.ProjectDir = C:\Users\User\Documents\cs\ex9-2\StringHandling\ +build_property.EnableComHosting = +build_property.EnableGeneratedComInterfaceComImportInterop = diff --git a/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.assets.cache b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.assets.cache new file mode 100644 index 0000000..425461c Binary files /dev/null and b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.assets.cache differ diff --git a/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.csproj.BuildWithSkipAnalyzers b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.csproj.BuildWithSkipAnalyzers new file mode 100644 index 0000000..e69de29 diff --git a/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.csproj.CoreCompileInputs.cache b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.csproj.CoreCompileInputs.cache new file mode 100644 index 0000000..3aef279 --- /dev/null +++ b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.csproj.CoreCompileInputs.cache @@ -0,0 +1 @@ +8fd33773078341b5f53a0b8e4024d4f92549871ff0b1a0215fb7182cccc6f6f9 diff --git a/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.csproj.FileListAbsolute.txt b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.csproj.FileListAbsolute.txt new file mode 100644 index 0000000..dd910d0 --- /dev/null +++ b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.csproj.FileListAbsolute.txt @@ -0,0 +1,30 @@ +C:\Users\User\Documents\cs\Exercise Starts\Chapter 09\StringHandling\StringHandling\bin\Debug\netcoreapp3.1\StringHandling.exe +C:\Users\User\Documents\cs\Exercise Starts\Chapter 09\StringHandling\StringHandling\bin\Debug\netcoreapp3.1\StringHandling.deps.json +C:\Users\User\Documents\cs\Exercise Starts\Chapter 09\StringHandling\StringHandling\bin\Debug\netcoreapp3.1\StringHandling.runtimeconfig.json +C:\Users\User\Documents\cs\Exercise Starts\Chapter 09\StringHandling\StringHandling\bin\Debug\netcoreapp3.1\StringHandling.runtimeconfig.dev.json +C:\Users\User\Documents\cs\Exercise Starts\Chapter 09\StringHandling\StringHandling\bin\Debug\netcoreapp3.1\StringHandling.dll +C:\Users\User\Documents\cs\Exercise Starts\Chapter 09\StringHandling\StringHandling\bin\Debug\netcoreapp3.1\StringHandling.pdb +C:\Users\User\Documents\cs\Exercise Starts\Chapter 09\StringHandling\StringHandling\obj\Debug\netcoreapp3.1\StringHandling.csproj.GenerateResource.cache +C:\Users\User\Documents\cs\Exercise Starts\Chapter 09\StringHandling\StringHandling\obj\Debug\netcoreapp3.1\StringHandling.GeneratedMSBuildEditorConfig.editorconfig +C:\Users\User\Documents\cs\Exercise Starts\Chapter 09\StringHandling\StringHandling\obj\Debug\netcoreapp3.1\StringHandling.AssemblyInfoInputs.cache +C:\Users\User\Documents\cs\Exercise Starts\Chapter 09\StringHandling\StringHandling\obj\Debug\netcoreapp3.1\StringHandling.AssemblyInfo.cs +C:\Users\User\Documents\cs\Exercise Starts\Chapter 09\StringHandling\StringHandling\obj\Debug\netcoreapp3.1\StringHandling.csproj.CoreCompileInputs.cache +C:\Users\User\Documents\cs\Exercise Starts\Chapter 09\StringHandling\StringHandling\obj\Debug\netcoreapp3.1\StringHandling.dll +C:\Users\User\Documents\cs\Exercise Starts\Chapter 09\StringHandling\StringHandling\obj\Debug\netcoreapp3.1\StringHandling.pdb +C:\Users\User\Documents\cs\Exercise Starts\Chapter 09\StringHandling\StringHandling\obj\Debug\netcoreapp3.1\StringHandling.genruntimeconfig.cache +C:\Users\User\Documents\cs\Exercise Starts\Chapter 09\StringHandling\StringHandling\obj\Debug\netcoreapp3.1\StringHandling.frmMain.resources +C:\Users\User\Documents\cs\ex9-2\StringHandling\bin\Debug\netcoreapp3.1\StringHandling.exe +C:\Users\User\Documents\cs\ex9-2\StringHandling\bin\Debug\netcoreapp3.1\StringHandling.deps.json +C:\Users\User\Documents\cs\ex9-2\StringHandling\bin\Debug\netcoreapp3.1\StringHandling.runtimeconfig.json +C:\Users\User\Documents\cs\ex9-2\StringHandling\bin\Debug\netcoreapp3.1\StringHandling.runtimeconfig.dev.json +C:\Users\User\Documents\cs\ex9-2\StringHandling\bin\Debug\netcoreapp3.1\StringHandling.dll +C:\Users\User\Documents\cs\ex9-2\StringHandling\bin\Debug\netcoreapp3.1\StringHandling.pdb +C:\Users\User\Documents\cs\ex9-2\StringHandling\obj\Debug\netcoreapp3.1\StringHandling.frmMain.resources +C:\Users\User\Documents\cs\ex9-2\StringHandling\obj\Debug\netcoreapp3.1\StringHandling.csproj.GenerateResource.cache +C:\Users\User\Documents\cs\ex9-2\StringHandling\obj\Debug\netcoreapp3.1\StringHandling.GeneratedMSBuildEditorConfig.editorconfig +C:\Users\User\Documents\cs\ex9-2\StringHandling\obj\Debug\netcoreapp3.1\StringHandling.AssemblyInfoInputs.cache +C:\Users\User\Documents\cs\ex9-2\StringHandling\obj\Debug\netcoreapp3.1\StringHandling.AssemblyInfo.cs +C:\Users\User\Documents\cs\ex9-2\StringHandling\obj\Debug\netcoreapp3.1\StringHandling.csproj.CoreCompileInputs.cache +C:\Users\User\Documents\cs\ex9-2\StringHandling\obj\Debug\netcoreapp3.1\StringHandling.dll +C:\Users\User\Documents\cs\ex9-2\StringHandling\obj\Debug\netcoreapp3.1\StringHandling.pdb +C:\Users\User\Documents\cs\ex9-2\StringHandling\obj\Debug\netcoreapp3.1\StringHandling.genruntimeconfig.cache diff --git a/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.csproj.GenerateResource.cache b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.csproj.GenerateResource.cache new file mode 100644 index 0000000..c350774 Binary files /dev/null and b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.csproj.GenerateResource.cache differ diff --git a/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.designer.deps.json b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.designer.deps.json new file mode 100644 index 0000000..9bb9f82 --- /dev/null +++ b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.designer.deps.json @@ -0,0 +1,11 @@ +{ + "runtimeTarget": { + "name": ".NETCoreApp,Version=v3.1", + "signature": "" + }, + "compilationOptions": {}, + "targets": { + ".NETCoreApp,Version=v3.1": {} + }, + "libraries": {} +} \ No newline at end of file diff --git a/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.designer.runtimeconfig.json b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.designer.runtimeconfig.json new file mode 100644 index 0000000..fdc9c5f --- /dev/null +++ b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.designer.runtimeconfig.json @@ -0,0 +1,16 @@ +{ + "runtimeOptions": { + "tfm": "netcoreapp3.1", + "framework": { + "name": "Microsoft.WindowsDesktop.App", + "version": "3.1.0" + }, + "additionalProbingPaths": [ + "C:\\Users\\User\\.dotnet\\store\\|arch|\\|tfm|", + "C:\\Users\\User\\.nuget\\packages" + ], + "configProperties": { + "Microsoft.NETCore.DotNetHostPolicy.SetAppPaths": true + } + } +} \ No newline at end of file diff --git a/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.dll b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.dll new file mode 100644 index 0000000..70d0f6b Binary files /dev/null and b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.dll differ diff --git a/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.frmMain.resources b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.frmMain.resources new file mode 100644 index 0000000..6c05a97 Binary files /dev/null and b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.frmMain.resources differ diff --git a/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.genruntimeconfig.cache b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.genruntimeconfig.cache new file mode 100644 index 0000000..0022776 --- /dev/null +++ b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.genruntimeconfig.cache @@ -0,0 +1 @@ +873fc49950e2d4ba08597881862ee3b19a5d3d88e4805a060bf5a0e3ca65f2da diff --git a/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.pdb b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.pdb new file mode 100644 index 0000000..7b25e18 Binary files /dev/null and b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/StringHandling.pdb differ diff --git a/string_handling/StringHandling/obj/Debug/netcoreapp3.1/apphost.exe b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/apphost.exe new file mode 100644 index 0000000..dc74048 Binary files /dev/null and b/string_handling/StringHandling/obj/Debug/netcoreapp3.1/apphost.exe differ diff --git a/string_handling/StringHandling/obj/StringHandling.csproj.nuget.dgspec.json b/string_handling/StringHandling/obj/StringHandling.csproj.nuget.dgspec.json new file mode 100644 index 0000000..80771d1 --- /dev/null +++ b/string_handling/StringHandling/obj/StringHandling.csproj.nuget.dgspec.json @@ -0,0 +1,66 @@ +{ + "format": 1, + "restore": { + "C:\\Users\\User\\Documents\\cs\\ex9-2\\StringHandling\\StringHandling.csproj": {} + }, + "projects": { + "C:\\Users\\User\\Documents\\cs\\ex9-2\\StringHandling\\StringHandling.csproj": { + "version": "1.0.0", + "restore": { + "projectUniqueName": "C:\\Users\\User\\Documents\\cs\\ex9-2\\StringHandling\\StringHandling.csproj", + "projectName": "StringHandling", + "projectPath": "C:\\Users\\User\\Documents\\cs\\ex9-2\\StringHandling\\StringHandling.csproj", + "packagesPath": "C:\\Users\\User\\.nuget\\packages\\", + "outputPath": "C:\\Users\\User\\Documents\\cs\\ex9-2\\StringHandling\\obj\\", + "projectStyle": "PackageReference", + "configFilePaths": [ + "C:\\Users\\User\\AppData\\Roaming\\NuGet\\NuGet.Config", + "C:\\Program Files (x86)\\NuGet\\Config\\Microsoft.VisualStudio.Offline.config" + ], + "originalTargetFrameworks": [ + "netcoreapp3.1" + ], + "sources": { + "C:\\Program Files (x86)\\Microsoft SDKs\\NuGetPackages\\": {}, + "https://api.nuget.org/v3/index.json": {} + }, + "frameworks": { + "netcoreapp3.1": { + "targetAlias": "netcoreapp3.1", + "projectReferences": {} + } + }, + "warningProperties": { + "warnAsError": [ + "NU1605" + ] + } + }, + "frameworks": { + "netcoreapp3.1": { + "targetAlias": "netcoreapp3.1", + "imports": [ + "net461", + "net462", + "net47", + "net471", + "net472", + "net48", + "net481" + ], + "assetTargetFallback": true, + "warn": true, + "frameworkReferences": { + "Microsoft.NETCore.App": { + "privateAssets": "all" + }, + "Microsoft.WindowsDesktop.App.WindowsForms": { + "privateAssets": "none" + } + }, + "runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\8.0.100\\RuntimeIdentifierGraph.json" + } + } + } + } +} \ No newline at end of file diff --git a/string_handling/StringHandling/obj/StringHandling.csproj.nuget.g.props b/string_handling/StringHandling/obj/StringHandling.csproj.nuget.g.props new file mode 100644 index 0000000..af28506 --- /dev/null +++ b/string_handling/StringHandling/obj/StringHandling.csproj.nuget.g.props @@ -0,0 +1,15 @@ + + + + True + NuGet + $(MSBuildThisFileDirectory)project.assets.json + $(UserProfile)\.nuget\packages\ + C:\Users\User\.nuget\packages\ + PackageReference + 6.8.0 + + + + + \ No newline at end of file diff --git a/string_handling/StringHandling/obj/StringHandling.csproj.nuget.g.targets b/string_handling/StringHandling/obj/StringHandling.csproj.nuget.g.targets new file mode 100644 index 0000000..35a7576 --- /dev/null +++ b/string_handling/StringHandling/obj/StringHandling.csproj.nuget.g.targets @@ -0,0 +1,2 @@ + + \ No newline at end of file diff --git a/string_handling/StringHandling/obj/project.assets.json b/string_handling/StringHandling/obj/project.assets.json new file mode 100644 index 0000000..f2ab053 --- /dev/null +++ b/string_handling/StringHandling/obj/project.assets.json @@ -0,0 +1,71 @@ +{ + "version": 3, + "targets": { + ".NETCoreApp,Version=v3.1": {} + }, + "libraries": {}, + "projectFileDependencyGroups": { + ".NETCoreApp,Version=v3.1": [] + }, + "packageFolders": { + "C:\\Users\\User\\.nuget\\packages\\": {} + }, + "project": { + "version": "1.0.0", + "restore": { + "projectUniqueName": "C:\\Users\\User\\Documents\\cs\\ex9-2\\StringHandling\\StringHandling.csproj", + "projectName": "StringHandling", + "projectPath": "C:\\Users\\User\\Documents\\cs\\ex9-2\\StringHandling\\StringHandling.csproj", + "packagesPath": "C:\\Users\\User\\.nuget\\packages\\", + "outputPath": "C:\\Users\\User\\Documents\\cs\\ex9-2\\StringHandling\\obj\\", + "projectStyle": "PackageReference", + "configFilePaths": [ + "C:\\Users\\User\\AppData\\Roaming\\NuGet\\NuGet.Config", + "C:\\Program Files (x86)\\NuGet\\Config\\Microsoft.VisualStudio.Offline.config" + ], + "originalTargetFrameworks": [ + "netcoreapp3.1" + ], + "sources": { + "C:\\Program Files (x86)\\Microsoft SDKs\\NuGetPackages\\": {}, + "https://api.nuget.org/v3/index.json": {} + }, + "frameworks": { + "netcoreapp3.1": { + "targetAlias": "netcoreapp3.1", + "projectReferences": {} + } + }, + "warningProperties": { + "warnAsError": [ + "NU1605" + ] + } + }, + "frameworks": { + "netcoreapp3.1": { + "targetAlias": "netcoreapp3.1", + "imports": [ + "net461", + "net462", + "net47", + "net471", + "net472", + "net48", + "net481" + ], + "assetTargetFallback": true, + "warn": true, + "frameworkReferences": { + "Microsoft.NETCore.App": { + "privateAssets": "all" + }, + "Microsoft.WindowsDesktop.App.WindowsForms": { + "privateAssets": "none" + } + }, + "runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\8.0.100\\RuntimeIdentifierGraph.json" + } + } + } +} \ No newline at end of file diff --git a/string_handling/StringHandling/obj/project.nuget.cache b/string_handling/StringHandling/obj/project.nuget.cache new file mode 100644 index 0000000..026f9e8 --- /dev/null +++ b/string_handling/StringHandling/obj/project.nuget.cache @@ -0,0 +1,8 @@ +{ + "version": 2, + "dgSpecHash": "QbChM5GDv/7cqs9cbt/74oYtIQ3Kdrl2jAw+KZ+Yonf41KwX5G+2JNC717GyQ9+4oSBHJBeWSyF+9iafYMPRqw==", + "success": true, + "projectFilePath": "C:\\Users\\User\\Documents\\cs\\ex9-2\\StringHandling\\StringHandling.csproj", + "expectedPackageFiles": [], + "logs": [] +} \ No newline at end of file -- cgit 1.4.1