Click here to Skip to main content
11,501,968 members (64,762 online)
Rate this: bad
Please Sign up or sign in to vote.
See more: C# ASP.NET Javascript
Dear Friend,

I have create a web-page to display data.
I have used Tab Container in it.
Also I need to call C# function from JavaScript.
But Its not working. Kindly guide me on the same.

Code Below:
function Validate()
//Some Code
__doPostBack('TabContainer1_TabPanel1_Button1', "OnClick");
C# Code:
protected void Button1_Click(object sender, EventArgs e)
//Some Code
Posted 20-Feb-13 2:37am
Rate this: bad
Please Sign up or sign in to vote.

Solution 1

Sounds like you want to talk to server from client side. If so, there are ways to do it, like:
1. XMLHttpRequest[^]
2. Callback[^]
3. WebService call[^]
4. PageMethod[^]

Pick & Try that you find fit.
Marcus Kramer at 20-Feb-13 9:28am
Sandeep Mewara at 20-Feb-13 9:32am
Thanks Marcus.
Arunprasath Natarajan at 20-Feb-13 15:15pm
Sandeep Mewara at 20-Feb-13 22:46pm

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

Advertise | Privacy | Mobile
Web04 | 2.8.150520.1 | Last Updated 20 Feb 2013
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100