TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Hector Gerena
NA
20
603
Getting a 404 Note found - ajax
Nov 29 2017 9:10 PM
I'm getting a 404 not found whe calling a codebehind c# menthod. Here is my jquery-ajax
<script language="javascript" type="text/javascript">
$(document).ready(function () {
// debugger;
// alert('Passing by');
$('#CPH1_NADErbl1').click(function () {
alert("Inside the click function");
// var Selected = $("input[type='radio'][name='#CPH1_NADErbl1_0']:checked").val();
var Selected = $('#CPH1_NADErbl1 input:checked').val();
alert(Selected);
if (Selected == 1) {
alert("Inside the if condition when true");
$.ajax({
type: "POST",
contentType: "application/json; charset=utf-8",
url: "/EIS/EISForm2.aspx.cs/EvalNADE",
dataType: "json",
success: function (response){
alert("success");
},
error: function(response)
{
alert("success failed");
}
});
} else {
alert("Inside the else condition when false");
$("#CPH1_<%= BudAssg%>").val('');
$("#CPH1_<%= MediCon%>").val('');
}
});
});
</script>
Here is my method ..
[WebMethod]
public void EvalNADE()
{
// int i = NADErbl1.SelectedIndex;
if (NADErbl1.SelectedIndex == 0)
{
string op1 = NADErbl1.SelectedItem.Text;
Bind_Emp();
Bind_MDECnd();
}
else if (NADErbl1.SelectedIndex == 1)
{
string op2 = NADErbl1.SelectedItem.Text;
//BudAssg.DataSource = null;
}
}
The method is not on the roort, is one level down in he EIS folder.
Reply
Answers (
4
)
Ajax stringify json
Am havg this error that says cannot explicitly call operator