<%@ Page Language="C#" AutoEventWireup="true" MasterPageFile="~/Masters/AgentMaster.Master"
    CodeBehind="preferCountry.aspx.cs" Inherits="CasheeremitAgent.Customer.preferCountry" EnableEventValidation="false" %>


<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>
<asp:Content ID="Content1" ContentPlaceHolderID="cpHead" runat="server">
    <style type="text/css">
        .ui-datepicker-month {
            color: #FF4500;
        }
        .maxWidthGrid
    {
        max-width: 300px;
        overflow: hidden;
    }
        .ui-datepicker-year {
            color: #FF4500;
        }

        .style1 {
            font-size: 11px;
            color: #0458a0;
            font-weight: normal;
            padding: 0px 0px 0px 10px;
            width: 104px;
        }

        .style2 {
            width: 104px;
        }

        .style4 {
            width: 298px;
        }

        .Hide {
            display: none;
        }

        .span1 {
            width: 110px;
        }

        .mrg0Box {
            margin-left: 0px !important;
            width: 100% !important;
        }


        .aspNetDisabled {
            border: 1px solid #ccc;
            box-sizing: border-box;
            color: #777;
            display: block;
            font-size: 13px;
            padding: 6px;
            transition: all 0.5s ease 0s;
            width: 98%;
            background: #eee;
            border-radius: 0px;
        }

        #cpLyremit_rdGender_0 .aspNetDisabled {
            border: 0px !important;
        }
    </style>
    <script type="text/javascript">
    <%--    function DisplayProgress() {

            $find('<%=ModalPopupExtender2.ClientID %>').show();
            setTimeout('document.images["imgLoad"].src = "../Styles/images/loading.gif"', 10);
        }
        function Validate(validationgroupname) {

            if (Page_ClientValidate(validationgroupname)) {
                return 'success';
            }
        }

        function DisplayWaiting(validationgroup) {
            debugger;
            if (Validate(validationgroup) == 'success') {
                $find('<%=ModalPopupExtender2.ClientID %>').show();
                setTimeout('document.images["imgLoad"].src = "../Styles/images/loading.gif"', 10);
            }
        } --%>
   <%--     function validate_ID_FileSize(source, arguments) {
            debugger;
            arguments.IsValid = false;
            source.className = "errMsg";
            let filesiz = 0;
            let uploadControl = document.getElementById('<%= FileUpldID.ClientID %>');
            for (let i = 0; i < uploadControl.files.length; i++) {
                filesiz = filesiz + uploadControl.files[i].size;
            }
            //filesize = '<%=ConfigurationManager.AppSettings["UploadFileSize"].ToString() %>'
            if (uploadControl.files.length > 1) {
                source.innerHTML = "Please select maximum of 1 document.";
                arguments.IsValid = false;
            }
            else if (filesiz > '<%=ConfigurationManager.AppSettings["UploadFileSize"].ToString() %>') {
                source.innerHTML = "File Size exceeds the limit.Please try uploading smaller size files.";
                arguments.IsValid = false;
            }
            else {
                arguments.IsValid = true;
            }
        } --%>
    <%--    function validate_Add_FileSize(source, arguments) {
            debugger;
            arguments.IsValid = false;
            source.className = "errMsg";
            let filesiz = 0;
            let uploadControl = document.getElementById('<%= FileUpldAddr.ClientID %>');
            for (let i = 0; i < uploadControl.files.length; i++) {
                filesiz = filesiz + uploadControl.files[i].size;
            }
            //filesize = '<%=ConfigurationManager.AppSettings["UploadFileSize"].ToString() %>'
            if (uploadControl.files.length > '<%=filelimitadd %>') {
                source.innerHTML = "Please select maximum of " + '<%=filelimitadd %>' + " document(s).";
                arguments.IsValid = false;
            }
            else if (filesiz > '<%=filesizeadd %>') {
                source.innerHTML = "File Size exceeds the limit.Please try uploading smaller size files.";
                arguments.IsValid = false;
            }
            else {
                arguments.IsValid = true;
            }
        } --%>
        <%--function validate_Add_FileSize(source, arguments) {

            arguments.IsValid = false;
            source.className = "errMsg";

            var uploadControl = document.getElementById('<%= FileUpldAddr.ClientID %>');
            var filesize = '<%=ConfigurationManager.AppSettings["UploadFileSize"].ToString() %>'

            if (uploadControl.files[0].size > filesize) {
                source.innerHTML = "FileSize exceeds the limit.please try uploading smaller size files.";
                arguments.IsValid = false;
            }
            else {
                arguments.IsValid = true;
            }
        }--%>
        function swalalert(val, typ) {
            swal({
                title: "",
                text: val,
                type: typ,
                showConfirmButton: true,
                confirmButtonColor: "#DD6B55",
                confirmButtonText: "OK",
                closeOnConfirm: true
            });
        }

        function swaRedirect(val, typ) {
            swal({
                title: "",
                text: val,
                type: typ,
                showConfirmButton: true,
                confirmButtonColor: "#DD6B55",
                confirmButtonText: "OK",
                closeOnConfirm: false
            }, function (isConfirm) {
                if (isConfirm) {
                    window.location.href = '<%=redurl %>';
                }
                else {
                }
            });
        }


    <%--    function AdrsDetails_HS() {
            var msg = '<%=ConfigurationManager.AppSettings["GBG_Off_Msg"].ToString() %>';
            swal({ title: "", text: msg, type: "info" });
        } --%>
        
     <%--   function DisplayProgress() {

            $find('<%=ModalPopupExtender2.ClientID %>').show();
            setTimeout('document.images["imgLoad"].src = "../Styles/images/loading.gif"', 10);
        } --%>
   <%--     function validate_ID_FileSize(source, arguments) {

            arguments.IsValid = false;
            source.className = "errMsg";

            var uploadControl = document.getElementById('<%= FileUpPOID.ClientID %>');
            var filesize = '<%=ConfigurationManager.AppSettings["UploadFileSize"].ToString() %>'

            if (uploadControl.files[0].size > filesize) {
                source.innerHTML = "FileSize exceeds the limit.please try uploading smaller size files.";
                arguments.IsValid = false;
            }
            else {
                arguments.IsValid = true;
            }
        } --%>
        window.document.title = "Profile Registration";
    </script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="cpLyremit" runat="server">
    
    <div class=" span7  margB20  margL20 nomrgMobil">
        <script src="../Scripts/js/jquery-ui-1.8.4.custom.min.js?v=1.1" type="text/javascript"></script>
        <script type="text/javascript">
            window.addEventListener("load", DatePicker);
            function DatePicker() {
                debugger;
                var date = new Date();
                var currentMonth = date.getMonth();
                var currentDate = date.getDate();
                var currentYear = date.getFullYear();

                <%--        $('#<%= txtIDExpiry.ClientID %>').datepicker({
                    inline: true,
                    dateFormat: 'dd/mm/yy',
                    numberOfMonths: [1, 1],
                    showOn: "button",
                    buttonImage: "../Styles/images/date.jpg",
                    buttonImageOnly: true,
                    //minDate: new Date(currentYear, currentMonth, currentDate),
                    minDate: 1,
                    //minDate: '-100y',
                    changeMonth: true,
                    changeYear: true,
                    //maxDate: '1',
                    yearRange: '1950:' + (new Date().getFullYear() + 20)
                    //maxDate: '-10y'
                });
            } --%>

                <%--   function DatePicker1() {

                $('#<%= txtIssuDate.ClientID %>').datepicker({
                    inline: true,
                    dateFormat: 'dd/mm/yy',
                    showOn: "button",
                    buttonImage: "../Styles/images/date.jpg",
                    buttonImageOnly: true,
                    changeMonth: true,
                    changeYear: true,
                    yearRange: '-100y:c+nn',
                    maxDate: '-1d'
                });
            } --%>


                <%--     function ShowAvailMobile() {

                $.ajax({
                    type: "POST",
                    url: "RemitterRegistration.aspx/CheckMobile",
                    data: '{mobile: "' + $("#<%=txtMobile.ClientID%>")[0].value + '" }',
                    contentType: "application/json; charset=utf-8",
                    dataType: "json",
                    success: OnSuccessM
                });
            } --%>

                <%--    function OnSuccessM(response) {
                var mesg1 = $("#mesgmob")[0];

                switch (response.d) {
                    case "true":
                        //mesg.style.color = "green";
                        mesg1.className = "spn_msg_H";
                        mesg1.innerHTML = "";
                        break;
                    case "false":
                        document.getElementById("<%=txtMobile.ClientID %>").value = "";
                        mesg1.className = "spn_msg_V";
                        mesg1.style.color = "red";
                        mesg1.innerHTML = "Mobile Number already exists";
                        break;
                    case "error":
                        mesg1.class = "spn_msg_V";
                        mesg1.style.color = "red";
                        mesg1.innerHTML = "Error occured";
                        break;
                }
            } --%>

                <%--     function ShowAvailability() {

                $.ajax({
                    type: "POST",
                    url: "RemitterRegistration.aspx/CheckUserName",
                    data: '{userName: "' + $("#<%=txtEmailId.ClientID%>")[0].value + '" }',
                    contentType: "application/json; charset=utf-8",
                    dataType: "json",
                    success: OnSuccess
                });
            } --%>

                <%--  function OnSuccess(response) {
                var mesg = $("#mesg")[0];

                switch (response.d) {
                    case "true":
                        //mesg.style.color = "green";
                        mesg.className = "spn_msg_H";
                        mesg.innerHTML = "";
                        break;
                    case "false":
                        document.getElementById("<%=txtEmailId.ClientID %>").value = "";
                        mesg.className = "spn_msg_V";
                        mesg.style.color = "red";
                        mesg.innerHTML = "EmailID already exists";
                        break;
                    case "error":
                        mesg.class = "spn_msg_V";
                        mesg.style.color = "red";
                        mesg.innerHTML = "Error occured";
                        break;
                }
            } --%>
            } </script>
       
        <script type="text/javascript">

        <%--  $(document).ready(startupscripts);
            Sys.WebForms.PageRequestManager.getInstance().add_endRequest(startupscripts); --%>

            // Page_ClientValidate JavaScript function will make sure that all Validators have validated the form and the validation 
            //is successful then only it will raise the JavaScript confirmation.

       <%--     function Day_onchange() {

                var year = document.getElementById("<%=ddlyear.ClientID %>");
                var month = document.getElementById("<%=ddlmonth.ClientID %>");
                var day = document.getElementById("<%=ddlday.ClientID %>");

                var selected_year = year.value.toString();
                var selected_month = month.value.toString();
                var selected_day = day.value.toString();

                $('#<%=hdnf_Day.ClientID %>').val(selected_day);
                $('#<%=hdnf_Mnth.ClientID %>').val(selected_month);
                $('#<%=hdnf_Yr.ClientID %>').val(selected_year);
            }
            --%>
         <%--   function Populate_yr_month() {
                var pres_year = new Date().getFullYear();
                var endyr_rng = parseInt('<%=ConfigurationManager.AppSettings["endyr_rng"].ToString() %>');
                var endyr = pres_year - endyr_rng;
                var startyr_rng = parseInt('<%=ConfigurationManager.AppSettings["startyr_rng"].ToString() %>');
                var startyr = endyr - startyr_rng;

                var list_yr = document.getElementById('<%=ddlyear.ClientID%>');

                var newListItem = document.createElement('OPTION');
                newListItem.text = "Year";
                newListItem.value = "0";
                list_yr.options.add(newListItem);

                for (y = endyr; y >= startyr; y--) {
                    var newListItem = document.createElement('OPTION');
                    newListItem.text = y;
                    newListItem.value = y;
                    list_yr.options.add(newListItem);
                }

                var list_mth = document.getElementById('<%=ddlmonth.ClientID%>');
                var months = ["Month", "JAN", "FEB", "MAR", "APR", "MAY", "JUN", "JUL", "AUG", "SEP", "OCT", "NOV", "DEC"];
                for (m = 0; m < months.length; m++) {
                    var newListItem = document.createElement('OPTION');
                    newListItem.text = months[m];

                    if (m < 10)
                        newListItem.value = "0" + m.toString();
                    else
                        newListItem.value = m;

                    list_mth.options.add(newListItem);
                }
            } --%>

       <%--     function Populate_day() {
                var yearID = document.getElementById("<%=ddlyear.ClientID %>");
                var monthID = document.getElementById("<%=ddlmonth.ClientID %>");
                var list_day = document.getElementById("<%=ddlday.ClientID %>");

                var year = parseInt(yearID.value.toString());
                var month = parseInt(monthID.value.toString());

                $('#<%=ddlday.ClientID %>').empty();
                var newlistitem = document.createElement('OPTION');
                newlistitem.text = "Day";
                newlistitem.value = "0";
                list_day.options.add(newlistitem);

                switch (month) {
                    case 01:
                    case 03:
                    case 05:
                    case 07:
                    case 08:
                    case 10:
                    case 12:
                        for (i = 1; i <= 31; i++) {
                            var newListItem = document.createElement('OPTION');
                            if (i < 10) {
                                newListItem.text = "0" + i.toString();
                                newListItem.value = "0" + i.toString();
                            }
                            else {
                                newListItem.text = i.toString();
                                newListItem.value = i.toString();
                            }

                            list_day.options.add(newListItem);
                        }
                        break;

                    case 4:
                    case 6:
                    case 9:
                    case 11:
                        for (i = 1; i <= 30; i++) {
                            var newListItem = document.createElement('OPTION');
                            if (i < 10) {
                                newListItem.text = "0" + i.toString();
                                newListItem.value = "0" + i.toString();
                            }
                            else {
                                newListItem.text = i.toString();
                                newListItem.value = i.toString();
                            }

                            list_day.options.add(newListItem);
                        }
                        break;

                    case 2:
                        if ((year % 400 == 0) || (year % 100 != 0 && year % 4 == 0)) {
                            for (i = 1; i <= 29; i++) {
                                var newListItem = document.createElement('OPTION');
                                if (i < 10) {
                                    newListItem.text = "0" + i.toString();
                                    newListItem.value = "0" + i.toString();
                                }
                                else {
                                    newListItem.text = i.toString();
                                    newListItem.value = i.toString();
                                }

                                list_day.options.add(newListItem);
                            }
                        }
                        else {
                            for (i = 1; i <= 28; i++) {
                                var newListItem = document.createElement('OPTION');
                                if (i < 10) {
                                    newListItem.text = "0" + i.toString();
                                    newListItem.value = "0" + i.toString();
                                }
                                else {
                                    newListItem.text = i.toString();
                                    newListItem.value = i.toString();
                                }

                                list_day.options.add(newListItem);
                            }
                        }
                        break;
                }
            } --%>



       <%--     function blockSpace(e) {

                var keyCode;
                if ($.browser.msie)
                    keyCode = e.keyCode;
                else
                    keyCode = e.which;

                if (keyCode == 32)
                    return false;
            } --%>

          <%--  function Validate(validationgroupname) {
                if (Page_ClientValidate(validationgroupname)) {
                    return 'success';
                }
            } --%>

          <%--  function IDTypeAlertMsg() {
                swal({ title: "", text: "Please enter your correct details,this cannot be changed Later.", type: "info" });
            } --%>

          <%--   function InvalidDOB() {
                swal({ title: "", text: "please select a valid DOB.", type: "error" });
            } --%>

       <%--     function GBG_Off_Alert() {

                var msg = '<%=ConfigurationManager.AppSettings["GBG_Off_Msg"].ToString() %>';
                swal({ title: "", text: msg, type: "info" });
                document.getElementById('divselectadrs').style.display = "none";
                document.getElementById('divlstadrs').style.display = "none";
                document.getElementById('<%= divfindadrs.ClientID %>').style.display = "none";
            }
             --%>
          <%--   function Validate(validationgroupname) {
                //            
                if (Page_ClientValidate(validationgroupname)) {
                    return 'success';
                }
            }  --%>

             <%--  function IDTypes() {
                //
                $("#Step1").slideUp(750);
                setTimeout(function () {
                    $("#dvStep12").slideDown();
                    $("#Ioctop1").hide();
                    $("#dvStep1").removeClass("box-typ4 rec-his-box working");
                    $("#dvStep1").addClass("box-typ4 rec-his-box complete");
                }, 750);
                DatePicker();
                DatePicker1();
            }  --%>


           <%--   function Trim(str) {
                while (str.substring(0, 1) == ' ') // check for white spaces from beginning
                {
                    str = str.substring(1, str.length);
                }
                while (str.substring(str.length - 1, str.length) == ' ') // check white space from end
                {
                    str = str.substring(0, str.length - 1);
                }

                return str;
            }   --%>

       <%--     function valOtherPassport(source, args) {
                //
                var passNo1 = document.getElementById('<%= PassportOther1.FindControl("txtPassport1").ClientID%>');
                var passNo2 = document.getElementById('<%= PassportOther1.FindControl("txtPassport2").ClientID%>');
                var passNo3 = document.getElementById('<%= PassportOther1.FindControl("txtPassport3").ClientID%>');
                var passNo4 = document.getElementById('<%= PassportOther1.FindControl("txtPassport4").ClientID%>');
                var passNo5 = document.getElementById('<%= PassportOther1.FindControl("txtPassport5").ClientID%>');
                var passNo6 = document.getElementById('<%= PassportOther1.FindControl("txtPassport6").ClientID%>');
                var passNo7 = document.getElementById('<%= PassportOther1.FindControl("txtPassport7").ClientID%>');
                var passNo8 = document.getElementById('<%= PassportOther1.FindControl("txtPassport8").ClientID%>');
                var passNo9 = document.getElementById('<%= PassportOther1.FindControl("txtPassport9").ClientID%>');
                source.className = "errMsg";

                if (passNo1.value != "") {
                    var passport1 = Trim(passNo1.value);
                    if ((passport1.length > 0) && (passport1.length == 9)) {

                        if (passNo2.value != "") {
                            var passport2 = Trim(passNo2.value);
                            if ((passport2.length > 0) && (passport2.length == 1)) {

                                if (passNo3.value != "") {
                                    var passport3 = Trim(passNo3.value);
                                    if ((passport3.length > 0) && (passport3.length == 3)) {

                                        if (passNo4.length != "") {
                                            var passport4 = Trim(passNo4.value);
                                            if ((passport4.length > 0) && (passport4.length == 7)) {

                                                if (passNo5.value != "") {
                                                    var passport5 = Trim(passNo5.value);
                                                    if ((passport5.length > 0) && (passport5.length == 1)) {

                                                        if (passNo6.value != "") {
                                                            var passport6 = Trim(passNo6.value);
                                                            if ((passport6.length > 0) && (passport6.length == 7)) {

                                                                if (passNo7.value != "") {
                                                                    var passport7 = Trim(passNo7.value);
                                                                    if ((passport7.length > 0) && (passport7.length == 14)) {


                                                                        if (passNo8.value != "") {
                                                                            var passport8 = Trim(passNo8.value);
                                                                            if ((passport8.length > 0) && (passport8.length == 1)) {

                                                                                if (passNo9.value != "") {
                                                                                    var passport9 = Trim(passNo9.value);
                                                                                    if ((passport9.length > 0) && (passport9.length == 1)) {


                                                                                        args.IsValid = true;

                                                                                    } else {
                                                                                        source.innerHTML = "Enter valid Passport number";
                                                                                        passNo9.focus();
                                                                                        args.IsValid = false;
                                                                                    }

                                                                                } else {
                                                                                    source.innerHTML = "Enter valid Passport number";
                                                                                    passNo9.focus();
                                                                                    args.IsValid = false;
                                                                                }




                                                                            } else {
                                                                                source.innerHTML = "Enter valid Passport number";
                                                                                passNo8.focus();
                                                                                args.IsValid = false;
                                                                            }

                                                                        } else {
                                                                            source.innerHTML = "Enter valid Passport number";
                                                                            passNo8.focus();
                                                                            args.IsValid = false;
                                                                        }




                                                                    } else {
                                                                        source.innerHTML = "Enter valid Passport number";
                                                                        passNo7.focus();
                                                                        args.IsValid = false;
                                                                    }

                                                                } else {
                                                                    source.innerHTML = "Enter valid Passport number";
                                                                    passNo7.focus();
                                                                    args.IsValid = false;
                                                                }



                                                            } else {
                                                                source.innerHTML = "Enter valid Passport number";
                                                                passNo6.focus();
                                                                args.IsValid = false;
                                                            }

                                                        } else {
                                                            source.innerHTML = "Enter valid Passport number";
                                                            passNo6.focus();
                                                            args.IsValid = false;
                                                        }


                                                    } else {
                                                        source.innerHTML = "Enter valid Passport number";
                                                        passNo5.focus();
                                                        args.IsValid = false;
                                                    }

                                                } else {
                                                    source.innerHTML = "Enter valid Passport number";
                                                    passNo5.focus();
                                                    args.IsValid = false;
                                                }
                                            } else {
                                                source.innerHTML = "Enter the valid Passport number";
                                                passNo4.focus();
                                                args.IsValid = false;
                                            }

                                        } else {
                                            source.innerHTML = "Enter the valid Passport number";
                                            passNo4.focus();
                                            args.IsValid = false;
                                        }

                                    } else {
                                        source.innerHTML = "Enter the valid Passport number";
                                        passNo3.focus();
                                        args.IsValid = false;
                                    }

                                }
                                else {
                                    source.innerHTML = "Enter the valid Passport number";
                                    passNo3.focus();
                                    args.IsValid = false;
                                }

                            } else {
                                source.innerHTML = "Enter the valid Passport number";
                                passNo2.focus();
                                args.IsValid = false;
                            }

                        } else {
                            source.innerHTML = "Enter the valid Passport number";
                            passNo2.focus();
                            args.IsValid = false;

                        }

                    } else {
                        source.innerHTML = "Enter the valid Passport number";
                        passNo1.focus();
                        args.IsValid = false;
                    }
                } else {
                    source.innerHTML = "Enter the valid Passport number";
                    passNo1.focus();
                    args.IsValid = false;
                }
            } --%>

            // Fun to stay @ PD 
          </script>

                <div class="clearfix">
        &nbsp;
    </div>
        <div id="dvRemSerch" runat="server" >
                    <asp:HiddenField ID="Shdnf_Day" runat="server" />
                    <asp:HiddenField ID="Shdnf_Mnth" runat="server" />
                    <asp:HiddenField ID="Shdnf_Yr" runat="server" />
                    <asp:Panel ID="pnlRemSrch" runat="server" DefaultButton="btnRemSrch">
                        <div class="BG_Gray mrg20-T">
                            <div class="pulLft">
                              <%--  <asp:UpdatePanel ID="UpdatePanel2" runat="server" UpdateMode="Conditional">
                                    <ContentTemplate>--%>
                                        <div class="row mrg10-T">
                                            <div class="col-md-2 TxtalinRgt TxtLable">
                                                <asp:Label ID="lblRemtID" runat="server" Text="Remitter ID"></asp:Label>
                                            </div>
                                            <div class="col-md-4">
                                                <asp:TextBox ID="txtSRemtID" class="txtboxM" runat="server"></asp:TextBox>
                                                <asp:RegularExpressionValidator ID="regRemID" runat="server" ControlToValidate="txtSRemtID"
                                                    Display="Dynamic" CssClass="errMsg" ValidationGroup="RemSrch" ErrorMessage="Please enter a valid RemitterID"
                                                    ValidationExpression="^(([a-zA-Z0-9]\s?){1,50})$"></asp:RegularExpressionValidator>
                                            </div>
                                        </div>
                                       
                                       
                                       
                                      
                                  <%--  </ContentTemplate>
                                </asp:UpdatePanel>--%>
                            </div>
                        </div>
                        <div class="row mrg10-T">
                            <div class="col-md-2">
                                &nbsp;
                            </div>
                            <div class="col-md-4">
                                <asp:Button ID="btnRemSrch" runat="server" class="btnB mrgL0 " ValidationGroup="RemSrch"
                                    OnClientClick="DisplayWaiting('RemSrch')" OnClick="RemSearch_Click" Text="Search" />
                            </div>
                        </div>
                        <div class=" clrfx">
                            &nbsp;
                        </div>
                    </asp:Panel>
                </div>
              <div id="dvPreference" runat="server" >
                                <div class="col-md-12 mrg10-T">
                                    <div class="col-md-4 TxtalinRgt TxtLable2">
                                        Select Preferred Country for Remittance  
                                    <span class="starRed">*</span>
                                        <br />
                                    </div>
                                    <div class="col-md-6">
                                        <asp:Label ID="lblMsg" runat="server" Font-Size="Small" Visible="false" ForeColor="Red"></asp:Label>
                                    </div>
                                </div>
                                <div class="col-md-12 mrg10-T" style="color: red">
                                    To Allow speedy transactions, Please indicate all the countries and all the amounts you expect to send money to in the future.
                                </div>
                                <div class="clrfx">
                                    &nbsp; </div>
                                <div style="padding: 10px;" class="overflowMob">
                                  <asp:GridView ID="gvCtry" Width="100%"  runat="server" AutoGenerateColumns="False" AllowPaging="True" class="tbl-typ2" OnPageIndexChanging="gvCtry_PageIndexChanging" OnRowDataBound="gvCtry_RowDataBound"
                                     
                                      DataKeyNames="Remitter_ID,Name,Alpha_3_Code,Reason_For_Transaction,Remittance_Per_Month,Approx_Amount"
                                      ShowFooter="True" EmptyDataText="No Prefeered country Added" CellPadding="6" CellSpacing="2" GridLines="None" HeaderStyle-CssClass="tbl-head"
                                      RowStyle-CssClass="tbl-data">
                                      <RowStyle HorizontalAlign="Left" />
                                      <Columns>
                                          <asp:TemplateField  HeaderText="Select the country you would like to send money (in the future)" >
                                              <ItemTemplate>
                                                  <asp:Label ID="lblCtryNme" runat="server" Text='<%# Eval("Name")%>'></asp:Label>
                                              </ItemTemplate>
                                              <FooterTemplate>
                                                  <asp:DropDownList ID="ddlPrefCtry" CssClass="text_box2" runat="server" Style="width: 98%; padding: 5px;" DataTextField="Country_Name"
                                                      DataValueField="Alpha_3_Code"
                                                      ValidationGroup="A">
                                                  </asp:DropDownList>
                                                  <br />
                                                  <asp:RequiredFieldValidator ID="rqfPrefCountry" runat="server" ErrorMessage="Please Select Preferred Country"
                                                      InitialValue="0" CssClass="errMsg" ControlToValidate="ddlPrefCtry" ValidationGroup="A"
                                                      Display="Dynamic"></asp:RequiredFieldValidator>
                                              </FooterTemplate>
                                            
                                          </asp:TemplateField>
                                          <asp:TemplateField  HeaderText="Purpose of the transaction">
                                              <ItemTemplate>
                                                  <asp:Label ID="lblResn" runat="server" Text='<%# Eval("Reason_For_Transaction")%>'></asp:Label>
                                              </ItemTemplate> 
                                              <EditItemTemplate>
                                                  <asp:TextBox ID="txtEdtReason" class="TxtBox resnBox" runat="server" Text='<%# Eval("Reason_For_Transaction")%>'
                                                      TextMode="MultiLine" Rows="5" MaxLength="200"></asp:TextBox><br />
                                                  <asp:RequiredFieldValidator ID="reqReason" runat="server" ErrorMessage="Please Enter reason for Remittance"
                                                      CssClass="errMsg" ControlToValidate="txtEdtReason" ValidationGroup="U"
                                                      Display="Dynamic"></asp:RequiredFieldValidator>
                                              </EditItemTemplate>                                           
                                              <FooterTemplate>
                                                  <asp:TextBox ID="txtReason" class="TxtBox resnBox" runat="server"
                                                      TextMode="MultiLine" Rows="5" MaxLength="200"></asp:TextBox><br />
                                                  <asp:RequiredFieldValidator ID="reqReason" runat="server" ErrorMessage="Please Enter Approximate Amount Of Remittance"
                                                      CssClass="errMsg" ControlToValidate="txtReason" ValidationGroup="A"
                                                      Display="Dynamic"></asp:RequiredFieldValidator>
                                              </FooterTemplate>
                                              
                                          </asp:TemplateField>
                                          <asp:TemplateField  HeaderText="Approximate number of transaction you would like to send per month?">
                                              <ItemTemplate>
                                                  <asp:Label ID="lblRemitPerMth" runat="server" Text='<%# Eval("Remittance_Per_Month")%>'></asp:Label>
                                              </ItemTemplate>
                                                <EditItemTemplate>
                                                  <asp:TextBox ID="txtEdtRemitPerMonth" class="TxtBox" runat="server" Text='<%# Eval("Remittance_Per_Month")%>' MaxLength="3"></asp:TextBox><br />
                                                  <asp:RequiredFieldValidator ID="reqRemPerMth" runat="server" ErrorMessage="Please Enter Remittance per Month"
                                                      CssClass="errMsg" ControlToValidate="txtEdtRemitPerMonth" ValidationGroup="b"
                                                      Display="Dynamic"></asp:RequiredFieldValidator><br />
                                                  <asp:RegularExpressionValidator ID="regRemtPerMth" runat="server" ControlToValidate="txtEdtRemitPerMonth"
                                                      ValidationExpression="^(([0-9]\s?){1,3})$" ErrorMessage="Please Enter valid Remittance per Month"
                                                      Display="Dynamic" ValidationGroup="U" CssClass="errMsg" />
                                                
                                              </EditItemTemplate>
                                              <FooterTemplate>
                                                  <asp:TextBox ID="txtRemitPerMonth" class="TxtBox" runat="server" MaxLength="3"></asp:TextBox><br />
                                                  <asp:RequiredFieldValidator ID="reqRemPerMth" runat="server" ErrorMessage="Please Enter Remittance per Month"
                                                      CssClass="errMsg" ControlToValidate="txtRemitPerMonth" ValidationGroup="A"
                                                      Display="Dynamic"></asp:RequiredFieldValidator><br />
                                                  <asp:RegularExpressionValidator ID="regRemtPerMth" runat="server" ControlToValidate="txtRemitPerMonth"
                                                      ValidationExpression="^(([0-9]\s?){1,3})$" ErrorMessage="Please Enter valid Remittance per Month"
                                                      Display="Dynamic" ValidationGroup="A" CssClass="errMsg" />
                                              </FooterTemplate>
                                         
                                          </asp:TemplateField>
                                          <asp:TemplateField  HeaderText="Approximate amount you would like to send per transaction (GBP)">
                                              <ItemTemplate>
                                         
                                                  <asp:Label ID="lblCtryAmt" runat="server" Text='<%# Eval("Approx_Amount") %>'></asp:Label>
                                              </ItemTemplate> 
                                              <EditItemTemplate>
                                                  <asp:TextBox ID="txtEdtApprxAmt" class="TxtBox" runat="server" MaxLength="12" Text='<%# Eval("Approx_Amount") %>'></asp:TextBox><br />
                                                  <asp:RequiredFieldValidator ID="reqApprxAmt" runat="server" ErrorMessage="Please Enter Approximate Amount Of Remittance"
                                                      CssClass="errMsg" ControlToValidate="txtEdtApprxAmt" ValidationGroup="U"
                                                      Display="Dynamic"></asp:RequiredFieldValidator><br />
                                                  <asp:RegularExpressionValidator ID="regApprAmt" runat="server" ControlToValidate="txtEdtApprxAmt"
                                                      ValidationExpression="^(([0-9.]\s?){1,12})$" ErrorMessage="Please Enter valid Approximate Amount"
                                                      Display="Dynamic" ValidationGroup="U" CssClass="errMsg" />
                                                  <asp:RangeValidator ID="RanRemtPerTrn"  runat="server" ControlToValidate="txtEdtApprxAmt" ErrorMessage="Maximum amount per transaction is 2,500 GBP."
                                                     MaximumValue="2500.00" MinimumValue="0.00" Type="Double" SetFocusOnError="true" Display="Dynamic" ValidationGroup="U" CssClass="errMsg"></asp:RangeValidator>
                                              </EditItemTemplate>                                            
                                              <FooterTemplate>
                                                  <asp:TextBox ID="txtApprxAmt" class="TxtBox" runat="server" MaxLength="12"></asp:TextBox><br />
                                                  <asp:RequiredFieldValidator ID="reqApprxAmt" runat="server" ErrorMessage="Please Enter Approximate Amount Of Remittance"
                                                      CssClass="errMsg" ControlToValidate="txtApprxAmt" ValidationGroup="A"
                                                      Display="Dynamic"></asp:RequiredFieldValidator><br />
                                                  <asp:RegularExpressionValidator ID="regApprAmt" runat="server" ControlToValidate="txtApprxAmt"
                                                      ValidationExpression="^(([0-9.]\s?){1,12})$" ErrorMessage="Please Enter valid Approximate Amount"
                                                      Display="Dynamic" ValidationGroup="A" CssClass="errMsg" />
                                                    <asp:RangeValidator ID="RangeRemtPerTrn"  runat="server" ControlToValidate="txtApprxAmt" ErrorMessage="Maximum amount per transaction is 2,500 GBP."
                                                     MaximumValue="2500.00" MinimumValue="0.00" Type="Double" SetFocusOnError="true" Display="Dynamic" ValidationGroup="A" CssClass="errMsg"></asp:RangeValidator>
                                              </FooterTemplate>
                                             
                                          </asp:TemplateField>
                                          <asp:TemplateField ShowHeader="False">   
                                               
                                              <FooterTemplate>
                                                  <asp:Button ID="btnAdd" runat="server" Text="Add" Visible="true" OnClick="AddNewCountry"
                                                      ValidationGroup="A" CssClass="btn btn-green mrgB10" />
                                                  <asp:Button ID="btnClear" runat="server" Text="Clear" Visible="true" OnClick="ClearCustomer"
                                                      CausesValidation="false" CssClass="btn btn-info" />
                                              </FooterTemplate>
                                          </asp:TemplateField>
                                      </Columns>
                                      <PagerStyle BackColor="White" ForeColor="White" Width="200px" HorizontalAlign="Center"
                                          CssClass="pgg" />
                                      <AlternatingRowStyle BackColor="White" />
                                  </asp:GridView>
                                  <div class="clrfx">
                                      &nbsp;
                                  </div>
                                    <asp:Button ID="btnSendMoney" runat="server"   Text="SendMoney" Visible="false" OnClick="btnSendMoney_Click"/> 
                              </div>
                                                        
                            </div>
    </div>
        
        </asp:Content>