private void EditUser()
        {
            string username = tbUsername.Text;

            lblAmendError.Text = "";
            bool success = false;

            try
            {
                using (QCAstServiceClient client = new QCAstServiceClient())
                {
                    success = client.EditUser(int.Parse(tbUserId.Text), ddlProfiles.SelectedIndex, username,
                                              tbPassword.Text,
                                              ddlClient.SelectedValue != ""
                                                  ? int.Parse(ddlClient.SelectedValue)
                                                  : (int?)null);
                }
                if (success)
                {
                    ClearTextAndListBoxes();
                    lblSuccess.Text = string.Format("User {0} has been successfully amended", username);
                }
                else
                {
                    lblAmendError.Text = "The user could not be amended at this time";
                }
            }
            catch (Exception ex)
            {
                NotifyWebmasterOfError("Billing", "User Management EditUser", ex.ToString());
                lblAmendError.Text =
                    "The website encountered a problem updating the User details.  The webmaster has been notified and will be attending to it shortly";
            }
        }