C# Tutorials and offshore development in India
    Tutorials   Resources   Forum   Communities   Interview   Jobs   Projects   Offshore Development    
Silverlight Tutorials | Mentor | Code Converter | Articles | Code Factory | Computer Jokes | Members | Peer Appraisal | IT Companies | Bookmarks | Revenue Sharing |


Prizes & Awards
My Profile



Active Members
TodayLast 7 Days more...

New Feature: Community Sites: Create your own .NET community website and start earning from Google AdSense ! It's Free !




Event handlers in sharepoint


Posted Date: 04 Sep 2008      Total Responses: 2

Posted By: S.Boovaragan       Member Level: Silver     Points: 1


How to write event handler in sharepoint
For example i can create button theough .aspx page in the sharepoint
where to write event handlers in sharepoint




Responses

Author: Ravi     04 Sep 2008Member Level: SilverRating:     Points: 1
Hi,
For event handler you have to use "Future"
Future work like deployment unit.


Author: Srinivas     19 Oct 2008Member Level: GoldRating:     Points: 6
Hi boovargan

you can create webpart with events and add them to gac.
Following is the sample code for button click event


protected TextBox t;
protected Button b;

protected override void CreateChildControls()
{
base.CreateChildControls();
b.Click += new EventHandler(onbuttonclick);
}
private void onbuttonclick(object sender, EventArgs e)
{
t.Text = "web part";
}
protected override void Render(System.Web.UI.HtmlTextWriter writer)
{
base.Render(writer);
writer.Write("<table></tabe>");
b.RenderControl(writer);
t.RenderControl(writer);
}



Post Reply
You must Sign In to post a response.
Next : Implementing Functionality in Sharepoint Designer
Previous : SharePoint
Return to Discussion Forum
Post New Message
Category: Sharepoint

Related Messages



dotNet Slackers   BizTalk Adaptors    Web Design

internet fax

Contact Us    Privacy Policy    Terms Of Use