Click here to Skip to main content
15,890,512 members
Home / Discussions / ASP.NET
   

ASP.NET

 
AnswerRe: Grid Refresh Pin
AhsanS29-Sep-08 21:13
AhsanS29-Sep-08 21:13 
QuestionOutLook In ASP.Net Application Pin
nikhil123429-Sep-08 18:08
nikhil123429-Sep-08 18:08 
AnswerRe: OutLook In ASP.Net Application Pin
Abhijit Jana29-Sep-08 18:34
professionalAbhijit Jana29-Sep-08 18:34 
GeneralRe: OutLook In ASP.Net Application Pin
nikhil123429-Sep-08 18:55
nikhil123429-Sep-08 18:55 
QuestionHidden fields with GET/POST Pin
Member 391904929-Sep-08 15:35
Member 391904929-Sep-08 15:35 
QuestionHow to call a eventhandler ? Pin
NewToAspDotNet29-Sep-08 13:31
NewToAspDotNet29-Sep-08 13:31 
AnswerRe: How to call a eventhandler ? Pin
Christian Graus29-Sep-08 13:56
protectorChristian Graus29-Sep-08 13:56 
QuestionCookies .. ? how to solve this problem? Pin
blackeyes29-Sep-08 13:10
blackeyes29-Sep-08 13:10 
Hi all
I have a question about the cookies did not know where the error
Private Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
        If Request.Cookies("UserName") IsNot Nothing Then
            Response.Cookies.Set(Request.Cookies("UserName"))
        Else
            Response.Cookies.Set(New HttpCookie("UserName", ""))
        End If
        Response.Cookies("UserName").Expires = Now.AddMinutes(30)
    End Sub

    Protected Overloads Overrides Sub OnPreRender(ByVal e As System.EventArgs)
        If Response.Cookies("UserName").Value = Request.Cookies("UserName").Value Then
            Response.Cookies.Remove("UserName")
        End If
        MyBase.OnPreRender(e)
    End Sub


In another place, I set the cookies when a user's login
If Log.Statu = LoginEnum.OK Then
            HttpContext.Current.Response.Cookies("UserName").Value = row("username")
            HttpContext.Current.Response.Cookies("UserName").Expires = Now.AddMinutes(30)
End If


In another place again, I set the cookies when the user logout
HttpContext.Current.Response.Cookies("UserName").Expires = Now.AddMinutes(-30)


The problem is : when user login and click any link in page i find cookies have been deleted Mad | :mad:

What issueConfused | :confused: ?
AnswerRe: Cookies .. ? how to solve this problem? Pin
AlexeiXX329-Sep-08 17:17
AlexeiXX329-Sep-08 17:17 
GeneralRe: Cookies .. ? how to solve this problem? Pin
blackeyes30-Sep-08 4:54
blackeyes30-Sep-08 4:54 
GeneralRe: Cookies .. ? how to solve this problem? Pin
AlexeiXX330-Sep-08 5:46
AlexeiXX330-Sep-08 5:46 
GeneralRe: Cookies .. ? how to solve this problem? Pin
blackeyes30-Sep-08 6:56
blackeyes30-Sep-08 6:56 
QuestionHow can I fix the "run time error: could not load the type... " error? Pin
JUNEYT29-Sep-08 10:55
JUNEYT29-Sep-08 10:55 
AnswerRe: How can I fix the "run time error: could not load the type... " error? Pin
AhsanS29-Sep-08 21:14
AhsanS29-Sep-08 21:14 
QuestionRow n't getting Updated in Gridview [modified] Pin
SRKVELLANKI29-Sep-08 7:15
SRKVELLANKI29-Sep-08 7:15 
AnswerPOSTED ALL CODE--too long Pin
leckey29-Sep-08 7:28
leckey29-Sep-08 7:28 
QuestionBrowser TimeOut Pin
attalurisubbu29-Sep-08 5:14
attalurisubbu29-Sep-08 5:14 
AnswerRe: Browser TimeOut Pin
whatUrunning.com29-Sep-08 5:22
whatUrunning.com29-Sep-08 5:22 
AnswerRe: Browser TimeOut Pin
Brij29-Sep-08 18:26
mentorBrij29-Sep-08 18:26 
GeneralRe: Browser TimeOut Pin
Prasanna Kumar Pete29-Sep-08 23:42
Prasanna Kumar Pete29-Sep-08 23:42 
Questiongridview onclick Pin
eyeseetee29-Sep-08 4:25
eyeseetee29-Sep-08 4:25 
AnswerRe: gridview onclick Pin
whatUrunning.com29-Sep-08 4:33
whatUrunning.com29-Sep-08 4:33 
AnswerRe: gridview onclick Pin
nelsonpaixao29-Sep-08 13:44
nelsonpaixao29-Sep-08 13:44 
Questionfileuplode control file uploda problem [modified] Pin
UD(IA)29-Sep-08 4:23
UD(IA)29-Sep-08 4:23 
QuestionGrouping relevant data together while iterating throug them Pin
J-Cod3r29-Sep-08 4:00
J-Cod3r29-Sep-08 4:00 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.