CREATEPROCEDURE[dbo].[GetPermission]@userName varchar(50),@permission int output
ASBEGINselect@permission = PERMISSION from USERS where UserName =@userName
END;
-------------- using foreach loop using System; public class Program { public static void Main() { char charCout = 'o'; int Count = 0; string strFirst = "Hello World"; foreach(char chr in strFirst) { if (chr == charCout) { Count++;...
The primary difference is that a Partial View is designed to be rendered within other full Views and as a result it will not contain all of the markup that a full View might ( since it is designed to work within other Views ). For example, a normal View might look like this and contain all of the elements present in a traditional HTML page : <!DOCTYPE html> <html> <head> <meta charset = utf-8 /> <title> Example </title> </head> <body> <!-- Your Content Here --> </body> </html> where as a Partial View might only contain a small section that it needs to render and since it should be displayed within an existing View, it won't require the necessary tags like <head>, <html>, etc. because it is implied that these should already be present when a Partial View is rendered. An example partial View might look like this : <div> <!-- Example --> <ul> ...
Razor View Engine VS Web Form(ASPX) View Engine Razor View Engine Web Form View Engine Razor Engine is an advanced view engine that was introduced with MVC3. This is not a new language but it is a new markup syntax. Web Form Engine is the default view engine for the Asp.net MVC that is included with Asp.net MVC from the beginning. The namespace for Razor Engine is System.Web.Razor . The namespace for Webform Engine is System.Web.Mvc.WebFormViewEngine . The file extensions used with Razor Engine are different from Web Form Engine. It has .cshtml (Razor with C#) or .vbhtml (Razor with VB) extension for views, partial views, editor templates and for layout pages. The file extensions used with Web Form Engine are also like Asp.net Web Forms. It has .aspx extension for views, .ascx extension for partial views & editor templates and .master extension for layout/master pages. Razor has new and advance ...
Comments
Post a Comment