Project 3 finished

Signed-off-by: Amrit Panesar <apanesar@4195tech.com>
This commit is contained in:
Amrit Panesar committed 2015-04-14 20:32:08 -07:00
1 parent 142f7988d5
commit 46e5359581
5 files changed
+10 -1

No files matched your search

Binary file not shown.
Binary file not shown.
+10 -1
View File
@@ -253,11 +253,13 @@ private: System::Void button1_Click(System::Object^ sender, System::EventArgs^
if (word->Length > 2) if (word->Length > 2)
{ {
String^ t1 = word->Substring(0, 1); String^ t1 = word->Substring(0, 1);
/*
String^ tt = word->Substring(0, 2)->ToLowerInvariant(); String^ tt = word->Substring(0, 2)->ToLowerInvariant();
if (tt->Equals("qu")) if (tt->Equals("qu"))
{ {
t1 = word->Substring(0, 2); t1 = word->Substring(0, 2);
} }
*/
if (!numbers->Contains(t1)) if (!numbers->Contains(t1))
{ {
if (vowels->Contains(t1)) if (vowels->Contains(t1))
@@ -305,9 +307,11 @@ private: System::Void button2_Click(System::Object^ sender, System::EventArgs^
{ {
String^ wordbuff = gcnew String(""); String^ wordbuff = gcnew String("");
String^ d1 = word->Substring(0, 1);
if (!numbers->Contains(d1))
{
int start = word->LastIndexOf("ay"); int start = word->LastIndexOf("ay");
String^ t1 = word->Substring(start, 2); String^ t1 = word->Substring(start, 2);
String^ d1 = word->Substring(0, 1);
String^ c1 = word->Substring(start - 1, 1); String^ c1 = word->Substring(start - 1, 1);
String^ t2 = word->Substring(1, start -2); String^ t2 = word->Substring(1, start -2);
@@ -336,6 +340,11 @@ private: System::Void button2_Click(System::Object^ sender, System::EventArgs^
translated += word + " "; translated += word + " ";
} }
} }
else
{
translated += word + " ";
}
}
textBox3->Text = translated; textBox3->Text = translated;
} }
Binary file not shown.
Binary file not shown.