Using methods and properties of the HttpResponse class is risky and could potentially cause runtime abends. For example, invoking the methods Redirect or Write, or WriteFile circumvents essential execution paths in the CA Gen runtime that impact history handling. Accessing certain Properties may also cause the application server to throw exceptions.
Follow these steps:
// User written code should be inserted here.
HttpResponse res = (HttpResponse)IefRuntimeParm2.GetResponse();
HttpCookie cookie = new HttpCookie("LastVisit");
cookie.Value = DateTime.Now.ToString();
cookie.Expires = DateTime.Now.AddDays(1);
res.Cookies.Add(cookie);
|
Copyright © 2013 CA.
All rights reserved.
|
|