Friday, 27 November 2015

MVC application for Starters .

MVC is the framwork for creating Webapplication , in this we have bifercated the different components of the webapplicationas into different categories .

M stands for model , which menas the datalayer in the form of a model .

V stands for view this is the the html pages which is manupulated using the model and the controller.

C which means controller, the controller is the class having multiple methods these methods are used to call the views .

Basically the Controller is just a method function of the class inside the controller.MVC dll that is System.Web.MVC which

contains the details that how the calling process can be carried by the action method.

View are genrated using the Razor Engine which works when a view is called by the user. Razor engine Renders the whole html page and sends It as the response .

Lets have a small example of creating MVC application .
* Open visual studio.
* Click File option.
* Click new option.
* Click the project option to start creating a new project.
* Select the programming language as visual C#.
* Select Web from menu the then select ASP.Net MVC web application.
* Select the MVC from above section and click the MVC checkBox from the lower section .
* click OK.
* this will take few minutes to complete the process
* As you can see a small MVC template is in front of you now. when you directly hit F5 he template executes and the out is in front of you. This template is complete in itself . you can read a bit of programming how the things are created by the template.

I will soon upload a video to demonstrate how to create a simple MVC application .
For any further queries please contact below.

Functions in VB.Net ?

In we use procedure in place of function. Procedure is a group of statements which combined together perform a task. has two types of procedure

  • Functions 
  • Sub Procedure or Subs

Funcion returns a value where as sub are non- return type procedure.



Function FindMax(ByVal num1 As Integer, ByVal num2 As Integer) As Integer
   ' local variable declaration */
   Dim result As Integer
   If (num1 > num2) Then
       result = num1
       result = num2
   End If
   FindMax = result
End Function

Sub Procedure Or Sub's


   Sub CalculatePay(ByVal hours As Double, ByVal wage As Decimal)
      'local variable declaration
      Dim pay As Double
      pay = hours * wage
      Console.WriteLine("Total Pay: {0:C}", pay)
   End Sub

Please Subscribe or Comment!! if you need any other details please comment below.