G
Guest
This button click is fired for first time, but does not get fired for second
time if I click. It again fires 3rd time, but not 4th time and so on..
I want to button to be fired everytime.
I want to add new valyes to my Session of ArrayList type when Button is
clicked.
Can anyone help? Please let me know what I am doing wrong. Here is a sample
call:
private void oButton_Click(object sender, System.EventArgs e)
{
if (oPictureKeys.Count > 0) //loaded ArrayList Keys from database
Session["_Session_PictureKey"] = oPictureKeys; //Always have values
if (HttpContext.Current.Session["_Session_PictureKey"] != null)
{
ArrayList oList=null;
string szNewKey = "NewPictureKey"; //New key I want to insert
to Session
oList = (ArrayList)(Session["_Session_PictureKey"]);
oList.Add(szNewKey);
Session["_Session_PictureKey"]=oList;
}
}
time if I click. It again fires 3rd time, but not 4th time and so on..
I want to button to be fired everytime.
I want to add new valyes to my Session of ArrayList type when Button is
clicked.
Can anyone help? Please let me know what I am doing wrong. Here is a sample
call:
private void oButton_Click(object sender, System.EventArgs e)
{
if (oPictureKeys.Count > 0) //loaded ArrayList Keys from database
Session["_Session_PictureKey"] = oPictureKeys; //Always have values
if (HttpContext.Current.Session["_Session_PictureKey"] != null)
{
ArrayList oList=null;
string szNewKey = "NewPictureKey"; //New key I want to insert
to Session
oList = (ArrayList)(Session["_Session_PictureKey"]);
oList.Add(szNewKey);
Session["_Session_PictureKey"]=oList;
}
}