c # – What's wrong with these classes and variables bool?

I am doing a Windows forms application to request contact information. I created a class to trim the input text and check if the text box is empty. I also assigned patterns for the email and the phone number. However, the text does not follow the regular expression and does not detect exceptions either.

the form has only one button and you must compile and present the information inserted in the text box.

I used the Get request method for the collected strings of the text box. Here is the bool.

                bool GetPhone (ref string phonenumber)
{
bool success = true;
try
{
txtPhone.Text = Input.TrimText (txtPhone.Text);
if (Input.IsTextEmpty (txtPhone.Text))
launch new InputRequiredException ();

phonenumber = txtPhone.Text;
Regex Regphone = new Regex (@ "^ ( +  d {1,2}  s)?  (?  D {3} )?[s.-] d {3}[s.-] d {4} $ ");
Match matchphone = Regphone.Match (phone number);
yes (matchphone.xccess)
success = true;
otherwise, throw a new InputRequiredException ()
}
capture (exception error)
{
string remediation = "Enter a valid phone number.";
Input.ShowError (error, remediation);
Input.SelectText (txtPhone);
}
try
{
int Phone = Convert.ToInt32 (txtPhone.Text);

success = true;
}
capture (exception error)
{
string remediation = "Enter a valid phone number.";
Input.ShowError (error, remediation);
Input.SelectText (txtPhone);

}
return success
}

Entry class

                        Class entry
{

static public string TrimText (string A)
{
return A.Trim ();
}

static internal bool IsTextEmpty (string A)
{
if (string.IsNullOrEmpty (A))
{
true returns
}

plus
{
false return;
}
}

Internal static empty ShowError (object error, string correction)
{

}

static public vacuum SelectText (TextBox textBox1)
{
textBox1.SelectAll ();
}
}

Exception class

        internal class InputRequiredException: exception
{
Public InputRequiredException ()
{
}

Public InputRequiredException (string message): base (message)
{
message = "Invalid entry.";
}

Public InputRequiredException (string message, Exception innerException): base (message, innerException)
{
}

Protected entry exception (SerializationInfo information, StreamingContext context): base (information, context)
{
}
}

The form contains a button and the code to click on it is:

    private void btnContact_Click (sender object, EventArgs e)
{
// input variables
string amount = string.Empty;
string name = string.Empty;
string emailpattern = @ "^[A-Z0-9._%+-]+ @[A-Z0-9.-]+.[A-Z]{2,} $ ";
string phonenumber = @ "^ ( +  d {1,2}  s)?  (?  d {3} )?[s.-] d {3}[s.-] d {4} $ ";

// Date of contact
DateTime contactDate = DateTime.MinValue;

// Contact method
Method ContactMethod = ContactMethod.Unassigned;

// Collect tickets
Yes
(
GetContactDate (ref contactDate) &&
GetContactMethod (ref method) &&
GetEmail (ref emailpattern) &&
GetName (ref name) &&
GetQuantity (ref quantity) &&
GetPhone (reference phone number)
)
{
// Send contact request and close the form
string format =
"Your contact request has been entered.  N  n" +
"Quantity: {0}  n" +
"Name: {1}  n" +
"Email: {2}  n" +
"Phone: {3}  n" +
"Date of contact: {4: D}  n" +
"Contact method: {5}  n";
string msg = string.Format (format, quantity, name, email pattern, phone number, contact date, method);
MessageBox.Show (msg, Application.ProductName);

Close();
}
}

No errors are shown in the code and the program runs without problems, but I do not get the desired result. What I need from the code is to accept the entries in the text box, validate them according to the pattern of regular expressions and return the value entered by the user. The code must throw an exception if the text box is empty or the entry is not valid. Currently, the text box is accepting each and every one of the values, without any exception. If I do not enter any value, it simply returns the pattern. I am a total noob when it comes to coding and I understand that the code may have logical errors. If there is an error or a multiple error or if the code is simply not finished, do not hesitate to let me know.