public RedirectToRouteResult Index(string friendReqeust) { var user = (User)Session["User"]; var friendReqeusts = new FriendRequest() { User1 = user, User2 = new User() { Id = Convert.ToInt32(friendReqeust) } }; friendRequestManager.SentFriendReqeust(friendReqeusts); var Profile = profileManager.GetProfileByUserId(Convert.ToInt32(friendReqeust)); return(RedirectToAction("Index", "Profile", new { id = Profile.Id })); }