hi
refer below link
http://www.aspforums.net/Threads/704596/how-to-achive-data-from-session/
I use it to show lable in page in below I put example of Datatable that save in session:
Id
|
Name
|
Quality
|
Buy
|
1
|
Titanic
|
MKV
|
Download
|
2
|
The Wolf
|
Mkv
|
Buy
|
3
|
Greem
|
Mkv
|
Download
|
according above link I define that
if (Session["Order"] != null)
{
DataTable dt = Session["Order"] as DataTable;
if (dt.Rows.Count > 0)
{
if (dt.Rows[0]["buy"].ToString().ToLower() == "buy")
{
PLLink.Visible =false;
PLBuy.Visible = true;
}
else
{
PLLink.Visible = true;
PLBuy.Visible = false;
}
}
}
now here I want if there was buy and Download in Buy column in session like above table it will:
PLLink.Visible =false;
PLBuy.Visible = true;
if in buy column be just Download like below:
Id
|
Name
|
Quality
|
Buy
|
1
|
Titanic
|
MKV
|
Download
|
3
|
Greem
|
Mkv
|
Download
|
it will :
PLLink.Visible =true;
PLBuy.Visible = false;
and if there were just buy in buy column like:
Id
|
Name
|
Quality
|
Buy
|
1
|
Titanic
|
MKV
|
Buy
|
3
|
Greem
|
Mkv
|
Buy
|
it will:
PLLink.Visible =false;
PLBuy.Visible = true;
HOw I can do it?
Best regards
Neda