DotNet Solution

  • Home
  • Asp.net
    • Controls
    • DataControl
    • Ajax
  • Web Design
    • Html
    • Css
    • Java Script
  • Sql
    • Queries
    • Function
    • Stored Procedures
  • MVC
    • OverView
    • Create First Application
  • BootStrap
    • Collapse Function

Tuesday, 29 November 2016

Install Visual Stdio Step by Step Process

  Unknown       09:59       over view       No comments    


How to install visual studio 2015 Step by Step Process like =>

Step (1) : Once downloading is complete, run the installer. The following dialog will be displayed.


Step (2): Click the ‘Install’ button and it will start the installation process.

Once the installation process is completed successfully, you will see the following dialog

Step (3): Close this dialog and restart your computer if required.

Step (4): Open Visual Studio from the Start Menu, which will open the following dialog. It will take a while for the first time only for preparation.


Once all is done, you will see the main window of Visual Studio as shown in the following screenshot.
You are now ready to start your application.
Read More
  • Share This:  
  •  Facebook
  •  Twitter
  •  Google+

Friday, 25 November 2016

Auto Increment Id in Sql Server

  Unknown       12:13       Queries       No comments    

SQL server identity column values use in table

Steps-Firstly Open-> Sql Server Create Table -> First Field Like ID Usually Autoincrement=>
Table create then=>insert data in table=> then Select data show increment id.

The following SQL statement defines the "ID" column to be an auto-increment primary key field in the "Category" table (Given Category is Table Name and CategoryId And  CategoryName are Field  in Table

         Create table Category
             (
                   CategoryId INT IDENTITY(1,1) Primary Key,
                   CategoryName NVARCHAR(100)     
             )

  We use IDENTITY(1,1) in Table .
Where the 1,1 is the starting number is 1 and increment  by 1 that's the resion We use Identity(1,1)


In the example above, the starting value for IDENTITY is 1, and it will increment by 1 for each new record.
Exp. To specify that the "ID" column should start at value 10 and increment by 5, change it to IDENTITY(10,5).

Result-



   In This Following Image CategoryId Is Auto Increment And Id id Start with 1 and It Will 
    Increment By 1
    
  Use This Steps In Result-

  1. Create Table With Create Query.

  2. Insert Data With Insert Query.

  3.  Show Table Data Through Select Query in Sql Server.




Read More
  • Share This:  
  •  Facebook
  •  Twitter
  •  Google+

Thursday, 24 November 2016

MVC Framework Architecture

  Unknown       09:38       OverView       No comments    

MVC Flow-

MVC application takes place when certain request comes from the client. The diagram below shows the flow:

Flow Steps

  • 1.  The client browser sends request to the MVC Application.
  • 2.  Global.ascx receives this request and performs routing based on the URL of 3. incoming request using the RouteTable, RouteData, UrlRoutingModule and MvcRouteHandler objects.
  • 3.  This routing operation calls the appropriate controller and executes it using the IControllerFactory object and MvcHandler object's Execute method.
  • 4.  The Controller processes the data using Model and invokes the appropriate method using ControllerActionInvoker object
  • 5.  The processed Model is then passed to the View which in turn renders the final output.
Read More
  • Share This:  
  •  Facebook
  •  Twitter
  •  Google+

Wednesday, 23 November 2016

The Evolution of MVC

  Unknown       11:31       OverView       No comments    

Microsoft had introduced ASP.NET MVC in .Net 3.5,since then lots of new features have been added.The following table list brief history of ASP.NET MVC.



ASP.Net MVC 5.2 [Current]

1.  MVC Version -   Asp.Net MVC 5.2
2.  Release date -   28 August 2014
3.  Visual Studio - VS 2013
4.  .Net Version -  .Net 4.5 framework
5.   Features -    
                       1.   Attribute based routing
                       2.  Minor update of Asp.Net MVC5
                        3.  Asp.Net MVC 5 bug fixed

ASP.Net MVC 5

1.  MVC Version -   Asp.Net MVC 5.0
2.  Release date -   17 October 2013
3.  Visual Studio - VS 2013
4.  .Net Version -  .Net 4.5 Framework.
5.   Features -    
                       1.  Authentication filters
                       2.  One Asp.Net.
                       3.  Asp.Net Identity.
                       4.  Bootstrap support in MVC template.
                      5.  New Asp.Net scaffolding.
                       6. Authentication filters.
                       7.  Minor update of Asp.Net MVC5.
                       8.Asp.Net MVC 5 bug fixed.

ASP.Net MVC 4

1.  MVC Version -   Asp.Net MVC 4.0
2.  Release date -   15 August 2012 .
3.  Visual Studio - VS 2010 SP1 and VS 2012.
4.  .Net Version -  .Net 4.0/.Net 4.5 Framework.
5.   Features -    
                       1.  Add Window Azure SDK support feature.
                       2.  Bundling and Minification.
                       3.  Introduce Asp.Net Web API.
                       4.  Mobile Project Template using jquery mobile.
                      5.  Display Modes.

 ASP.Net MVC 3

1.  MVC Version -   Asp.Net MVC 3.0
2.  Release date -   13 January 2010
3.  Visual Studio - VS 2013
4.  .Net Version -  .Net 4.0 Framework
5.   Features -    
                       1.  Razor view engine.
                       2.  ViewBag dynamic property.
                       3.  Entity framework Code First.
                       4.  Global action filters.
                      5.  Dependency resolver for IoC.
                       6.  Remote validation.
                       7.  Compare Attribute.

ASP.Net MVC 2

1.  MVC Version -   Asp.Net MVC 2.0
2.  Release date -   10 March 2010
3.  Visual Studio - VS 2008
4.  .Net Version -  .Net 3.5/.Net 4.0 Framework
5.   Features -    
                       1.  Client side validation.
                       2.  Scaffolding.
                       3.  Asynchronous controller.
                       4.  Area for creating module based application.
                      5.  Lambda expression based Html helpers.
                       6.  DataAnnotation attribute
                       7.  Custom template Helper

ASP.Net MVC 1

1.  MVC Version -   Asp.Net MVC 1.0
2.  Release date -   13 March 2009
3.  Visual Studio - VS 2008
4.  .Net Version -  .Net 3.5 Framework
5.   Features -    
                       1.  MVC architecture pattern and web form engine
                       2.  Auto binding
                       3.  Ajax Helpers
                       4.  Html Helpers
                      5.  Routing
                       6.  Unit testing
                   



Read More
  • Share This:  
  •  Facebook
  •  Twitter
  •  Google+

Sunday, 20 November 2016

MVC vs ASP.NET

  Unknown       18:26       OverView       No comments    

There are various positive points to Using MVC

1.  TDD support out of the box as most of the design is based on interfaces.
2.  SEO friendly URL by design (though now this is possible in ASP.NET 4 as well)
3.  No ViewState (this may seem a bit of moving backward to some), but overall a good design    decision.
4.  Clean View Markup (no additional HTML emitted)
5.  100% extensible.  You can add your own controller with IOC, switch view engines at will, control model binding at wish etc.
6.   Rich UI support (possible through client side JS libraries like jQuery UI and others).  Telerik has released some controls for MVC which includes Grid control as well (which are merely HTMLHelpers)
7.  Session, JS, Ajax works.  Validation is even more powerful with DataAnnotations and jquery.
8.  Is MVC faster?  Yes by default because of lack of viewstate and clean markup.  But performance is subject and MVC by design is more performant that traditional ASP.NET webforms (though webforms can be made as fast as required.
9.  Out of the box support for mitigating antiforgery attacks and XSS vulnerability (though asp.net does has this to some extent)
10.  Out of the box minimal IOC support.
11.  Full control over rendered HTML
12.  Pluggable architecture


***ASP.NET WebForms developers migrating to ASP.NET MVC initially feel a little uncomfortable because they are unable to find many key features that were available in WebForms approach. There are many questions comes to their minds like below:

1. Web is still stateless but where is the Viewstate?
2. Where is that Code behind file?
3. What is that Razor syntax? Why I need it?
4. Where to find Page_Load method? that is used to put code for almost every page.
4. What about Binding and Rich Server Controls? Where these controls gone?
Read More
  • Share This:  
  •  Facebook
  •  Twitter
  •  Google+

Friday, 18 November 2016

Main Advantage Of MVC

  Unknown       11:28       OverView       No comments    

There Are Many Advantage of MVC(Model view & Controller)
1.  Faster development process.
2.  Easier to manage complexity (divide and conquer).
3.  It does not use server forms and view state.
4.  Front Controller pattern (rich routing).
5.  Better support for test-driven development.
6.  Ideal for distributed and large teams .
7.  High degree of control over the application behavior.
8.  Enables the full control over the rendered HTML.
9.  Provides clean separation of concerns(SoC).
10.  Enables Test Driven Development (TDD).
11.  Easy integration with JavaScript frameworks.
12.  Following the design of stateless nature of the web.
13.  RESTful urls that enables SEO.
14.  No ViewState and PostBack events.

Read More
  • Share This:  
  •  Facebook
  •  Twitter
  •  Google+

Wednesday, 16 November 2016

MVC OverView

  Unknown       08:54       OverView       No comments    

Introduction

The Model-View-Controller (MVC) architectural pattern separates an application into three main components: the model, the view, and the controller. The ASP.NET MVC framework provides an alternative to the ASP.NET Web Forms pattern for creating Web applications. The ASP.NET MVC framework is a lightweight, highly estable presentation framework that (as with Web Forms-based applications) is integrated with existing ASP.NET features, such as master pages and membership-based authentication. The MVC framework is defined in the System.Web.Mvc assembly.


Model:   
                 Model represents shape of the data and business logic.It maintains the data of The application. Model objects retrieve and store model state in a database.
                                   Note -     Model is a data and business logic.
View:  
              View is a user interface. View display data using model to the user and also enables them to   modify  the data.
                                   Note -  View is a User Interface.
Controller:
                       Controller handles the user request. Typically, user interact with View, which in-tern raises appropriate URL request, this request will be handled by a controller. The controller renders the appropriate view with the model data as a response.

                                 Note -   Controller is a request handler.



MVC Architecture

The following figure illustrates the flow of the user's request in ASP.NET MVC  See Above-.
                                             Request/Response in MVC Architecture                                      

As per the above figure, when the user enters a URL in the browser, it goes to the server and calls appropriate controller. Then, the Controller uses the appropriate View and Model and creates the
the response and sends it back to the user.


Read More
  • Share This:  
  •  Facebook
  •  Twitter
  •  Google+

Tuesday, 8 November 2016

Get Random Rows in SqlServer

  Unknown       12:03       Queries       No comments    

How To Get  Random  ROWS in  Table  Using Sql Server


Step 1- 
             Open Sql Server and Create Table like in Ex.

Ex.

Step 2-
              We want to  fetch Unique Randomly Rows and values in table  Then use query like

Syntax-   SELECT TOP 2 * FROM tbl_Randomvalues ORDER BY NEWID() 

Result


The key here is the NEWID function, which generates a globally unique identifier (GUID) in memory for each row.By definition, the GUID is unique and fairly random; so, when you sort by that GUID with the ORDER BY clause, you get a random ordering of the rows in the table.
So finaly we get Unique and Random rows by using this query. We use Top 2 its use to only Top 2 result in table.

SELECT TOP 2 * FROM tbl_Randomvalues ORDER BY NEWID() 



Read More
  • Share This:  
  •  Facebook
  •  Twitter
  •  Google+
Newer Posts Older Posts Home

Popular Posts

  • Auto Increment Id in Sql Server
    SQL server identity column values use in table Steps- Firstly Open-> Sql Server Create Table -> First Field Like ID Usually Autoi...
  • MVC Framework Architecture
    MVC Flow- MVC application takes place when certain request comes from the client. The diagram below shows the flow: Flow Steps ...
  • Create First MVC Application
    How to create MVC First simple application It is very easy to make application in mvc follow some steps and create first application ST...
  • Reset Identity Column in Sql Server
    We Want To Reset Identity Column Then Use Code.If We Delete column By Id Like We delete 5 no id and After Than we Insert New then We get 6...
  • Unicque Row Num and Same Rank in Sql server
     Use Of  Row_Number() ,Rank() function , Dense_Rank() Row_Number() This function will assign a unique id to each row returned from t...
  • Create Table
    Create Table In Sql Server Syntax- CREATE TABLE TableName ( ColumnName1  INT PRIMARY KEY IDENTITY, ColumnName2, ColumnName3 ) Ex.  C...
  • Email Validation In JavaScript
    We use Validation for Email  in Javascript like in above example <!DOCTYPE html> <html> <head> <script> fu...
  • Numeric Value Validation Through JavaScript
    Validate Only Numeric Value Enter In TextBox Using JavaScript function Firstly Write Java Script Function in <head tag> in Asp.Net ...
  • Asp.net- MultiView
    MultiView and View controls allow you to divide the content of a page into different groups, displaying only one group at a time. Each Vie...
  • The Evolution of MVC
    Microsoft had introduced ASP.NET MVC in .Net 3.5,since then lots of new features have been added.The following table list brief history of ...

Blog Archive

  • ▼  2016 ( 36 )
    • ►  February ( 1 )
    • ►  March ( 5 )
    • ►  April ( 1 )
    • ►  June ( 10 )
    • ►  July ( 6 )
    • ▼  November ( 8 )
      • Get Random Rows in SqlServer
      • MVC OverView
      • Main Advantage Of MVC
      • MVC vs ASP.NET
      • The Evolution of MVC
      • MVC Framework Architecture
      • Auto Increment Id in Sql Server
      • Install Visual Stdio Step by Step Process
    • ►  December ( 5 )
  • ►  2017 ( 1 )
    • ►  January ( 1 )
Powered by Blogger.

Categories

  • Ajax
  • AllFunction
  • Controls
  • CreateApplication
  • css
  • Function
  • javascript
  • Js
  • over view
  • OverView
  • Queries
  • StoredProcedures

Text Widget

Sample Text

Pages

  • Home

Copyright © DotNet Solution | Powered by Blogger
Design by Vibha Acharya