.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
 
Sign In
Register
 
Win Surprise Gifts!!!
Congratulations!!!


Top 5 Contributors of the Month
david stephan

Home >> Forum >> ASP.Net >> Post New QuestionBookmark and Share Subscribe to Forum

Datalist

Posted By: PriyankaReddyMeka     Posted Date: December 17, 2008    Points:2   Category :ASP.Net
Hi
I have used an Image Button in the Datalist.I have to redirect to another page on click on Image Button.I write code for that in ItemCommand.But my Itemcommand event is not fired.

Responses
Author: Rahul             
Posted Date: December 18, 2008     Points: 5   

Hi,
I guess you are binding the DataList in Page_Load Event. If yes then add !IsPostBack property or just modify your code like this


protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
// Bind you DataList Here
}
}


After this ItemCommand Event of DataList will be fired.



Post Reply

You must Sign In To post reply
 
 
Find more Forum Questions on C#, ASP.Net, Vb.Net, SQL Server and more Here
Quick Links For Forum Categories:
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  OOPs  SilverlightIISJQuery
JavaScript/VBScriptBiztalkWPFPatten/PracticesWCFOthers
www.DotNetSpark.comUnAnsweredAll

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend