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

Answer Posted / satish v itagi

I have made use of scripts in code behind. My client
wanted cursor to move from one web ui control to another in
a specific order based on the data fed/selected by user.
For eg. after entering specific word in a textbox, cursor
has to focus on save button bypassing all other ui
controls; if another specific word is entered focus should
jump on third ui control skipping the second, so on and so
forth.

User got delighted when the facility was given.

Another case where I implemented was to focus to next
control even after a post back event (otherwise smart
navigation returns focus to the same control after a post
back and use has to press tab key again to set focus to
next ui control).

This facility made my clients again happy.

Of course, it is more worthy to earn clients delight than
weighty pay packet!!!

Ofcourse, I used Page.RegisterStartupScript() and the
Page.RegisterClientScriptBlock() methods!

Is This Answer Correct ?    1 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the difference between a page theme and a global theme?

728


Who generates session id?

662


Why the javascript validation not run on the asp.net button but run successfully on the html button?

721


Whats the difference between abstract factory pattern and factory pattern?

795


1.how to encrpt query string in asp.net? 2.there are 10000 records then i wnat display 5000 records one gridview and 5000 records another grid view what is the process?

1882


Difference between web user control and web custom control?

666


What are the steps to follow to host a web application on a web server?

758


What is .net remoting?

794


What happens if an ASP.NET server control with event-handling routines is missing from its definition?

833


How you can return View from ASP.NET Web API method?

758


Explain the asp.net mvc folder conventions? : asp.net mvc

703


In how many ways we can retrieve table records count?

731


What is asp.net master page?

739


Explain the main differences between asp and asp.net?

712


How would ASP and ASP.NET applications run at the same time on the same server?

2163