Using JavaScript is not a big deal.
U can write JavaScript code any where in .aspx file
to write JavaScrip code u have to enter <scrpit> tag
your all JavaScript code will go in between this tag.
u can add as many as script tag u want and any where u want but better u keep it at one place, either in head or after body.
more more clear idea visit following link this is very nice tutorial about JavaScript and other web technology.
1.
JavaScript Tutorial[
^]
2. (Don't go for this if u r very Beginer for asp.net )
Using JavaScript Along with ASP.NET[
^]
3. (Use this as an example)
Client Side validations using JavaScript in ASP net Web Applications[
^]