Tech
Forums
Jobs
Books
Events
Interviews
Live
More
Learn
Training
Career
Members
Videos
News
Blogs
Login
Sign Up
Ask Question
2
Reply
How to redirect to another view
prabhu p
Jan 22 2018 2:41 AM
158
Reply
In MVC5, I have one question,
Iam calling one Action Method(second page) from jquery from First page button click
Everything working fine but atlast i need second action metod view want to load.
could any one help on this.
$(
'#report'
).click(
function
() {
debugger
$.ajax({
url:
'@Url.Action("loadreport", "Report")'
,
type:
'GET'
,
data: { Mid: $(Txt_Monitor).val() },
cache:
false
,
success:
function
(data) {
$(
"#contact"
).html(data);
$header = $(
'.header'
);
$(
"#div1"
).show();
$header1 = $(
'.header tr td'
);
var
x = $header.find(
'td'
);
var
k = $header1.find(
'div'
);
$(
'.panel-body'
).on(
'scroll'
,
function
() { $header.css(
'top'
, $(
this
).scrollTop()); });
//var wi = new Array();
//$('.dt tr').eq(0).find('td').each(function (e) {
// k.eq(e).width($(this).width() );
// wi.push(k.eq(e).width());
//});
$(
'.dt thead tr td div'
).each(
function
(e) {
k.eq(e).width($(
this
).width());
});
$(
"#spinner"
).hide();
},
error:
function
() {
// handle ajax error
$(
"#spinner"
).hide();
}
});
});
});
Second action method
public
ActionResult loadreport(
string
Mid)
{
int
TV = RTS.LoadTV(Mid);
ViewBag.loadreport = RTS.Loadreport(Mid, TV);
//ViewData["loadrep"] = new SelectList(loadreport, "Rel_Type", "Rel_Type");
return
View();
}
please help on this
Upload Source Code
Select only zip and rar file.
Post
Reset
Cancel
Answers (
2
)
Next Recommended Forum
How to fetch data from database for a particular FB account?
How to avoid the Page Refresh when date selected time