Click here to Skip to main content
15,920,603 members
Home / Discussions / ASP.NET
   

ASP.NET

 
Questionhow to slide the images those r in a folder by slide show control. Pin
rinku soni 235-Oct-09 2:51
rinku soni 235-Oct-09 2:51 
AnswerRe: how to slide the images those r in a folder by slide show control. Pin
sashidhar5-Oct-09 2:57
sashidhar5-Oct-09 2:57 
AnswerRe: how to slide the images those r in a folder by slide show control. Pin
Abhijit Jana5-Oct-09 5:35
professionalAbhijit Jana5-Oct-09 5:35 
GeneralRe: how to slide the images those r in a folder by slide show control. Pin
rinku soni 235-Oct-09 19:25
rinku soni 235-Oct-09 19:25 
Questionaspx page in iframe Pin
Member 38798815-Oct-09 2:20
Member 38798815-Oct-09 2:20 
AnswerRe: aspx page in iframe Pin
Abhijit Jana5-Oct-09 5:33
professionalAbhijit Jana5-Oct-09 5:33 
QuestionOpen new window from usercontrol hosted on ajax enabled page Pin
codeslingerCA5-Oct-09 1:55
codeslingerCA5-Oct-09 1:55 
QuestionSession State Cookie does not exist! Pin
Mark-1234567895-Oct-09 1:35
Mark-1234567895-Oct-09 1:35 
Hello world!

Can’t anyone help me with this problem.

When the user click a button I store some information in to a session cookie on the server (hope that is the correct terminology) When the page reloads and I try and recover the information from the session state cookie it tells me that the object does not exist.

“Object reference not set to an instance of an object.”

Thanks for you help

using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data;
using System.Data.SqlClient;
using System.Web.Security;
using System.IO;

public partial class login : System.Web.UI.Page
{
      public static clsGb_Cookie gb_cookies = new clsGb_Cookie();

      protected void Page_Load(object sender, EventArgs e)
      {
            if (IsPostBack == true)
            {
                  Serializer ser = new Serializer();
                  gb_cookies = ser.DeserializeCookie(Session["MCE-QLS"].ToString());
        
                  // depending on the cookie settings ie user role set the screen access

            }

      }

      public void btnLogin_Click(object sender, EventArgs e)
      {

            string strCon = ReadLocalConfigFile(); // Gets the DB connection string

            // CheckLoginDetails will have updated memory object gb_cookies with either
            // a valid users details OR "ERROR!" OR "USER NOT FOUND!"
            clsCheckLoginDetails checkLoginDetails = new clsCheckLoginDetails();
            checkLoginDetails.Validate(txbUserID.Text.ToString().Trim(),
                                                   txbPassword.Text.ToString().Trim(), strCon, gb_cookies);
           
            // Save the result from the login attemp to the cookie
            Serializer ser =   new Serializer();
            Session["MCE-QLS"] = ser.SerializeCookie(gb_cookies);

      }
AnswerRe: Session State Cookie does not exist! Pin
Abhijit Jana5-Oct-09 1:51
professionalAbhijit Jana5-Oct-09 1:51 
GeneralRe: Session State Cookie does not exist! Pin
Mark-1234567895-Oct-09 2:07
Mark-1234567895-Oct-09 2:07 
GeneralRe: Session State Cookie does not exist! Pin
Khaja A. Imtiaz5-Oct-09 5:17
Khaja A. Imtiaz5-Oct-09 5:17 
Questionhow to do it my post web? Pin
lockepeak5-Oct-09 1:27
lockepeak5-Oct-09 1:27 
QuestionTwitter/Facebook integration Pin
rahul.net115-Oct-09 1:08
rahul.net115-Oct-09 1:08 
AnswerRe: Twitter/Facebook integration Pin
sashidhar5-Oct-09 1:11
sashidhar5-Oct-09 1:11 
GeneralRe: Twitter/Facebook integration Pin
rahul.net115-Oct-09 2:50
rahul.net115-Oct-09 2:50 
GeneralRe: Twitter/Facebook integration Pin
sashidhar5-Oct-09 4:40
sashidhar5-Oct-09 4:40 
AnswerRe: Twitter/Facebook integration Pin
Sachin Dubey5-Oct-09 1:29
Sachin Dubey5-Oct-09 1:29 
Questionquestion from slide show control. Pin
rinku soni 235-Oct-09 1:08
rinku soni 235-Oct-09 1:08 
AnswerRe: question from slide show control. Pin
Sachin Dubey5-Oct-09 1:27
Sachin Dubey5-Oct-09 1:27 
Questionchange my crystal report connection string Pin
vikas shukla5-Oct-09 0:20
vikas shukla5-Oct-09 0:20 
AnswerRe: change my crystal report connection string Pin
sashidhar5-Oct-09 1:09
sashidhar5-Oct-09 1:09 
QuestionTreeView Control In ASP.net Pin
Sachin Dubey5-Oct-09 0:20
Sachin Dubey5-Oct-09 0:20 
AnswerRe: TreeView Control In ASP.net Pin
Manas Bhardwaj5-Oct-09 0:35
professionalManas Bhardwaj5-Oct-09 0:35 
GeneralRe: TreeView Control In ASP.net Pin
Sachin Dubey5-Oct-09 0:37
Sachin Dubey5-Oct-09 0:37 
AnswerRe: TreeView Control In ASP.net Pin
Abhijit Jana5-Oct-09 0:39
professionalAbhijit Jana5-Oct-09 0:39 

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.