What is Inline Function?

Inline functions are functions where the call is made to inline functions. The actual code then gets placed in the calling program. Normally, a function call transfers the control from the calling program to the function and after the execution of the program returns the control back to the calling program after the function call. These concepts of function saved program space and memory space are used because the function is stored only in one place and is only executed when it is called. This concept of function execution may be time consuming since the registers and other processes must … Click here to continue reading.

What’s the difference between Page.RegisterClientScriptBlock and Page.RegisterStartupScript?

RegisterClientScriptBlock is for returning blocks of client-side script containing functions. RegisterStartupScript is for returning blocks of client-script not packaged in functions-in other words, code that’s to execute when the page is loaded. The latter positions script blocks near the end of the document so elements on the page that the script interacts are loaded before the script runs.

<%@ Reference Control="MyControl.ascx" %>

C# Extension Methods

Sometimes it is necessary to add functionality to a library for which you do not own the source code and where using inheritance to subclass functionality is not viable. This problem can be overcome with the careful use of C# 3.0 extension methods.

An extension method is a type of method that was introduced in C# version 3.0. Extension methods allow you to create new functionality for existing data types, including classes,structures or interfaces, without modifying the code of the type itself. This permits new methods to be created for classes for which you have no access to the source … Click here to continue reading.

Client-Side versus Server-Side Validation

If you are new to Web application development, you might not be aware of the difference between client-side and server-side validation. Suppose that the end user clicks the Submit button on a form after filling out some information. What happens in ASP.NET is that this form is packaged in a request and sent to the server where the application resides. At this point in the request/response cycle, you can run validation checks on the information submitted. Doing this is called server-side validation because it occurs on the server.

On the other hand, supplying a script (usually in the form of … Click here to continue reading.