Wednesday 18 June 2008

ASP/AJAX - Notes

Learning ASP.Net, AJAX and CSS.
There are a number of ways to work with these features in Visual Studio.
For example, with CSS, it is possible to build a sheet by hand in notepad, but it is easier to add a sheet as a new item to a web project.




If you have an existing StyleSheet, it can also be dragged and dropped into the solution.
Elements can be added to the style sheet by hand, but it is easier to right click and choose "Build Style". That brings up this dialog:

You can add styles for Elements - standard HTML parts, or user defined names which need to go into Classes.

ASP.Net has a feature called master pages. If you have design features you want to show on all pages you add them to the master page, then when adding new pages you can select the master page you wish to apply. So you need only attach a style sheet to the master page and you can see the result of all design changes apply to all pages in the site.

Working with Master Pages.
To add a new aspx formto a project that references a master pages, go to Add Existing Item and choose Web Content Form. The next step will give you the oppourtunity to choose the master file to link too.

No comments: