Can we use the java script code in .Net Code behind?

Answer Posted / zikku

yes we can use javascript in code behind.


Define the script block that contains the JavaScript
function. You can add this directly to the HTML of the page.


Insert the script block by the
Page.RegisterStartupScript() or the
Page.RegisterClientScriptBlock() method.

or by using updatepanel by raising an async postback using
JavaScript code

Is This Answer Correct ?    10 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is marshalling ? Is it a part of asp.net ?

796


What is State Management in .Net and how many ways are there to maintain a state in .Net? What is view state?

767


Explain the components of web form in asp.net

736


Why is the standalone environment only useful during the development process?

1574


Differentiate between a hyperlink control and a linkbutton control.

714






Tell me the code snippet to show how we can return 404 errors from HttpError?

1010


if i wanna deploy my asp.net project to the production server and situation is that i m still not compiled my project i have as-is on my development side now on production server we dont have a visual studio now what kind of settings i need to be to do in webconfig /machine.config file to deploy my project and in iis too....

1812


What is the typical session identifier?

777


What are the components of ado.net?

692


What is route in web api?

714


When maintaining session through sql server, what is the impact of read and write operation on session objects?

731


What is s2s tracking?

721


Define repository pattern in mvc.net? : asp.net mvc

719


How long does an http session last?

677


What is the difference between Session and response.Redirect?

831