You can not directly fire a server side code from client side code by adding ANY event handler by adding it to attribute collection.
From client side code, only doPostBack function can fire a server side event handler.
So you need to call that _doPostback() function and sent the cooecr parameter so that doPostBack() function can fire a server side event handler.
This is really very strange that you are actually calling "Button1_Click" which is a server side event handler of "Button1" with so much hassle. You are calling Button1's event handler by Clikcing (firing client side event handler of Button2) "Button2". This is really not proper at all.
The whole thing which you have shown is equivalent to just clicking a server side asp.net button(yes as simple as that )
and a server side asp.net button actually calls the same _doPostback internally ( you never need to know that, actually when you use asp.net server side button !!! )
Now he can do it. The code below would execut the server code in the Button1_Click event.
Another example: say you are using the modal popup window in the ajax toolkit and you want to update your form when the window is closed.
You could set OnOkScript="callServerEvent();" and then you can run server side code when your window is closed.
when we create project just choosing option like Web Site project then dll is not created until we publish the whole site. so please tell me in which situation a user should choose Web Site project and why the dll file is not create if user choose Web Site project type.
<input type="button" id="button1" class="buttonsT" name="inputval30something^&()%#@!sabs" value="30 Something(1494)" title="Click this Button to log in as 30 Something(1494)" onclick="loginas('30something^&()%#@!sabs');">
In firefox there is "Error Console" which is great help for debugging any client side problem that occurs in using Mozila. You can try out that and please let us know that what exactly the problem is !!! It will easier for all to help you ...
if anyone could please give me pointers on how to do this if it's possible
I have a textbox and a button next to each other , now the user needs to click on the button to fill the textbox with a certain value. Now on the validation side , if the textbox has no value the requiredfield validator will give it's message calling the ValidatorCalloutExtender giving that ajax popup.
Now till there it's easy enough, but the thing is I need to display the ValidatorCalloutExtender pointing at the button and not the textbox.