0

hello you all,

thanks you all for solving my problems and helping and guiding me.

i have news titles with hyperlink in one page when i click on one of the news title then it will navigate to other page and will display news title and content there.

now i have passed session news_id to content dipslaying page in repeater.

<td><asp:HyperLink ID="HyperLink1" navigateurl='<%# String.Format("Default.aspx?News_Id={0}", Eval("News_Id")) %>' runat="server"><%#DataBinder.Eval(Container.DataItem,"News_Title") %></asp:HyperLink></td>

how can i receive news_title and News_content on other.

i have to fetch news_content from database and i m using asp.net2.0.

4
Contributors
4
Replies
5
Views
7 Years
Discussion Span
Last Post by __avd
0

hello you all,

thanks you all for solving my problems and helping and guiding me.

i have news titles with hyperlink in one page when i click on one of the news title then it will navigate to other page and will display news title and content there.

now i have passed session news_id to content dipslaying page in repeater.

<td><asp:HyperLink ID="HyperLink1" navigateurl='<%# String.Format("Default.aspx?News_Id={0}", Eval("News_Id")) %>' runat="server"><%#DataBinder.Eval(Container.DataItem,"News_Title") %></asp:HyperLink></td>

how can i receive news_title and News_content on other.

i have to fetch news_content from database and i m using asp.net2.0.

hi,

As of your code u r passing the News_id value using querystring. You can get the value on the other page using

Request.QueryString["New_id"];

But, u also need to get the value of "News_Title" too. Here, u have to pass the same through querystring.

But, the better way to go is Session.

Assign the required values to session as follows.

Session["News_id"]=News_id;
Session["News_title"]=News_title;

i hope this will help u. otherwise let me know.

Edited by murugavel84: n/a

0

explain ur case in detail..
wot do u want exactly..and which are the controls u r using to achieve this..!

0

i know how to use session and request.querystring but passing News_Id using hyperlink is new for me.

problem is that

when i pass News_Id using hyperlink from news.aspx it will navigate to news1.aspx page and there in repeater it will show the News_Title and News_content from database.
i have no idea how to do this??

please guide me about this idea

0

>news1.aspx page and there in repeater it will show the News_Title and News_content

Write code in Page_load handler that fetch rows from the table based upon given news_id.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.