In this page you can find important topics of Visual Basic .Net technology for SDSUV/HNB/UTU BCA/BSC(IT/CS) students: all the best !

Visual Basic .Net

Visualvisual basic.net is an object oriented programming language designed by Microsoft.By the name of the language only you can see that this is a language for beginners.Although the language is aimed at noobs.We should not underestimate the power of language itself there are people who criticize VB.net because the simplicity of the syntax but VB.net has the ability to create very powerful and sophisticated application VB.net is a great place to start because of easy and straight forward the syntax is easy.And you will find yourself not writing hundred of lines of code as there are many shortcut that make coding so much easier in this language the main part of the VB.net are

  1. Console application
  2. Window application
  3. Web application
  4. Class library
  5. Application deployment application
  6. WPF application
  7. Wcp application
  8. Web services

.Net Framework

  • The microsoft.net framework is a platform for building,deploying and running web services and application
  • It provide a highly productive standard based multi language environment for integrating existing investment with next generation application and services as well as the ability to solve the challenges of deployment and operation of internet-scale application.
  • The.NET framework consists of three main parts the:
    1. Hierarchical set of unified class libraries
    2. Organised version of active server pages called ASP.NET
    3. Common language Runtime

Common language Runtime(CLR)

  • CLR is the execution engine for .Net framework application
  • It provide code management, application memory isolation, verification of type safety,etc.

Console VB.net

  • Console application program has no graphic
  • It is pure text
  • It is easy to develop
  • It use few resources and is efficient
  • It won’t win you any visual design award but it will accomplish an analytical processing task

Example:-
Module module1
Sub Main()
Console.writeLine(“hello world”)
End Sub
End Module

Output

hello world

Vb.net Window form

an important part of visual basic is the ability to create window form application that run locally on using computer you can use visual studio to create the application and the user interface using windows form a window form application is built on classes from the system windows from namespace

Steps to create windows form are:

  1. Go to start menu
  2. All programs
  3. Go visual studio 2012
  4. Go to file menu then select project
  5. Select language VB
  6. Project dialogue box is open then select window form application
  7. Write application name and then select location where you want to save your application then click ok

You are done👍🏻

Integrated Development Environment (IDE)

An IDE normally consists of a source code editor, build automation tools, and a debugger. Most modern IDEs have also intelligent code completion.

For more information on IDE read here…

Difference between property and method

Method

Method is an action that respond to an event
For example: let’s say you have a button. A user click this button, which is the event.Your program should act according to the event,which it does by running the code inside a Method

Property

  • You specify global setting for your project by using project properties
  • This default setting control the appearance and behaviour of the item in your project throughout its life cycle
  • Properties are saved in the project’s .vbproj file, and kindcan be accessed through the property pages dialogue box

Garbage collection in Vb.net

Garbage collection is a mechanism that allows the computer to detect when an object can no longer be accessed.
It then automatically release the memory used by that object(as well as calling a clean up routine code called “finalizer” which is written by the user). Some garbage collector like the one used by .net compact memory and therefore decrease your program working set.

Data Types in Vb.net

Data types means the type of data that a variable holds. Data types present in vb.net are given in bellow figure:

Data types in vb.net

Data types in vb.net

Beside these string data type is also valid

Other important topic (for exams)

Difference between CUI and GUI

CUI and GUI are user interfaces used in connection with computer.
CUI is the precursor of GUI and stand for Character User interface where user has to type on keyboard to proceed on the other hand GUI stand for Graphical User Interface which make it possible to use a mouse instead of keyboard.
GUI is much more easier to navigate then CUI.
There is only text in case of CUI whereas there are graphics and other visual clues in case of GUI
Most modern computer used GUI and not CUI
DOS is an example of CUI wheras windows is an example of GUI

Difference between Procedural and Non-Procedural/OOP programming language

Procedural:

Programming language in which you have a pre defined structure to execute and write a program
You have a series of statement that you execute where you start with the first statement
The statement are executed in order from beginning to end
The program terminate after the last statement is executed
Example are:-FORTAN, COBOL, BASIC, C Pascal,etc

Non-procedural

Object oriented programming language that are event driven.
here you don’t just have a series of statement that are executed, you have several choices of different things You can do in a program to select the event that you want to occur. Only the code for the event is executed
Examplel: C plus plus,Java Visual Basic,etc

Event driven programming

Visual basic is an event driven driven programming language. It is very important to have a good concept of event driven programming. The common events are click, double click, load mouse move up, mouse down, keypress, keyup keydown, get focus, lost focus,etc
When the user fire 🔥 any event then that allows the particular block of code of the corresponding event procedure is executed then the program behave in a certain way. This is event driven programming

Do-While loop and While loop

Do-while: You should use Do while loop when you want to test condition first and if the condition evaluates to true then only you want to repeat the statement

While: while loop work differently it first check the condition and then work accordingly

Difference between VB 6 and VB.Net

VB6:

  1. Object based language
  2. Does not support threading
  3. Not powerful exception handling mechanism
  4. Does not having support for the console based application
  5. Cannot use more than one version of com object in VB application called dll error
  6. Does not support for the disconnected data sources

VB.Net

  1. Object Oriented Language
  2. Support threading
  3. Powerful exception handling mechanism
  4. Having support for the console based application
  5. More than one version of dll is supported
  6. Support the disconnected data source by using data set classes

Toolbox/Toolbar

Its a set of tools.
A Toolbox in Visual Basic consist of Controls, Containers, Menu Options, Crystal Report Controls, Data Controls, Dialogs, Components, Printing controls, that are used in a form to design the interfaces of an application.You can drag & drop the controls from toolbox on a vb form.

MessageBox

If you are using windows form, the easiest way to show a dialogue box or alert box is to call messagebox.show(). This result in a customisable dialogue box window. This is easier than implementing a dialogue yourself

(Difference Between ListBox and ComboBox)

LsitBox

The listbox represent a windows control to display a list of item to a user. A user can select an item from the list. It allow the programmer to add item to add at design time by using the properties window or at runtime

Example:

Listbox1.Items.Add(“India”)

Listbox1.Items.Add(“UP”)

Listbox1.Items.Add(“Saharanpur”)

ComboBox

The combobox control is used to display a dropdown list of variable item. It is a combination of a text box in which the user enters an item and a dropdownlist from which the user can selects an item.

Example:

ComboBox1.Items.Add(“Government”)

ComboBox1.Items.Add(“BJP”)

ComboBox1.Items.Add(“Vote”)

Function

function is a name the part of a program that can be invoked from the other part of a program

The function statement is used to declare the name parameter and the body of a function

Syntax for function:

[Modifiers] Function FunctionName [(Parameter List)] As ReturnType

[Statements]

End Function

Leave a Reply