Question mark within text in IE

Viewed 623

I have a page that will allow the user to enter multiple dates. I'm using devexpress object. Everything's working find in chrome but when I try it on IE, question mark is adding within the text like this : ?7?/?6?/?2017?, ?7?/?7?/?2017?

Can anyone help me with this? Below is my codes. Thank you!

Here is my DevExpress object

<dx:ASPxDropDownEdit ID="multidate" runat="server" Theme="Material" CssClass="object-style" Width="100%" ClientInstanceName="dd_multidate">
<DropDownWindowTemplate>
<dx:ASPxCalendar ID="ASPxCalendar1" runat="server" CssClass="objform-style" EnableMultiSelect="True" Theme="Material" FastNavStyle-Paddings-Padding="0px" ShowWeekNumbers="false">
 <DayStyle Font-Size="11px" Paddings-Padding="5px" CssClass="multidates"/>
 <ClientSideEvents SelectionChanged="OnSelectionChanged" Init="function(s,e) {
                    s.OnDayMouseDown = function(p1, p2, p3, p4) { ASPxClientCalendar.prototype.OnDayMouseDown.call(s, p1, p2, true, p4);     
                    }
            }"  />
</dx:ASPxCalendar>  
</DropDownWindowTemplate>
</dx:ASPxDropDownEdit>

This is how I get the selected dates

<script type="text/javascript">
    function OnSelectionChanged(s, e) {
        dd_multidate.SetText(s.GetSelectedDates().toLocaleString().replace(/12:00:00 AM,/g, " ").replace(/, 12:00:00 AM/, " ").replace(/ ‎12‎:‎00‎:‎00‎ ‎AM/g, ""));
        //dd_multidate.SetText(s.GetSelectedDates().toLocaleString().replace(/12:00:00 AM/g, "").replace(/, ,/g, ", ").replace(/, /g, ""));
        }
</script>

And below is my code for saving

<script type="text/javascript">
    $(document).on('click', '#MainContent_btn_submit', function () {
        var param = {};
        param.hdrid = $("#MainContent_TelNum").text();
        param.multidate = $("input[name='dd_multidate']").val();
        console.log(JSON.stringify(param));
        var request2 = $.ajax({
            //async: true,
            //cache: false,
            dataType: "json",
            type: "POST",
            contentType: "application/json; charset=UTF-8",
            url: "Instruction.aspx/save_multidate",
            data: JSON.stringify(param)
        });
    });
</script>

And this is my VB code

<Web.Services.WebMethod()> _
    Public Shared Function save_multidate(hdrid As String, multidate As String) As String
        ', less1 As String, net1 As String, aadd1 As String, bill1 As String, inc As String
        Dim cn As New SqlConnection(ConfigurationManager.ConnectionStrings("ofs").ConnectionString)
        Dim cmd As New SqlCommand
        cmd.Connection = cn
        cmd.CommandType = CommandType.StoredProcedure
        cmd.CommandText = "save_Instruction"
        cmd.Parameters.AddWithValue("@inst_hdrid", hdrid)
        cn.Open()
        cmd.ExecuteNonQuery()
        cn.Close()
        Return hdrid
    End Function
2 Answers
Related