c # – & # 39; Answer & # 39; does not contain a definition to & # 39; Redirect & # 39;

I'm trying to use Response.Redirect (url) in a .NET project, but I'm having some problems.

I am also using the AspNetSaml nuget package.

This is the error:

Error CS0117 & # 39; Answer & # 39; does not contain a definition to & # 39; Redirect & # 39;

I am already using the System.Web namespace and also added System.Web.dll

Empty static redirection (Answer samlResponse)
{
// specify the SAML provider url here, also known as "endpoint"
var samlEndpoint = "https://saml.alight.com/idp/SSO.saml2";

Request AuthRequest = new AuthRequest (
"https://www.xxxx.com/", // put the "unique ID" of your application here
"https://www.xxxx.com/" // Consumer URL assertion: the redirect URL where the provider will send authenticated users
);

// Generate the provider URL
string url = request.GetRedirectUrl (samlEndpoint);

Response.Redirect (url);


}