Common VB .Net Interview Preparation Guide
Download PDF

VB .Net Interview Questions and Answers guide to get preparation of VB .Net Jobs Interview or Learn the basic and advance concepts of VB .NET Programming by our VB .Net Interview Questions and Answers Guide.

69 VB .Net Questions and Answers:

Table of Contents:

Common  VB .Net Job Interview Questions and Answers
Common VB .Net Job Interview Questions and Answers

1 :: What is difference between import System.Data.SqlClient,System.Data.Oledb?

System.Data.OleDB It contains the objects that we use to connect to a data source via an OleDB provider , such as OleDbConnection, OleDBCOmmand. System.Data.SqlClient It contains objects that we use to connect to a data source via Tabular data stream interface provided by Microsoft Sql Server. This can be generally used to provide better performance because it removes some of the intermediate layers required by the OleDB provider.

2 :: Write the role of New keyword?

New is used to initialize a new object. We sets a variable to any dattype with help of New keyword .The New keyword gives a value to the variable.We can also uses new keyword to initialize an object variable.
Example:- dim obj as new SqlDataAdapter.

3 :: What is branching logic control in vb.net?

Function and subroutines are the answer.The diffrence in two of them is function send information back from where it is called means function can return a value but subroutines can not do this.

4 :: What is DataType conversion in VB.NET ?

Convert one variable type to another one is called datatype conversion we can also caleed this casting in VB.NET some automatically conversion is also there.
Cbool CByte CChar Cdate CDec CDbl CInt CLng CObj CShort CSng CStr CType Asc.

5 :: Explain about the Ruby interface generator?

Ruby interface generator is primarily responsible for providing the visual part of the Visual basic and this was clubbed with “EB” designed for Omega database system. VBX interface was added to this feature which had the ability to load dynamic link libraries.

6 :: Explain about the feature Anonymous type?

Anonymous type is a feature of VB.NET and it allows data types to be created from the code which requires it. This feature is present in VB as well as C#. They should be stored in variables declared with the keyword VAR. Dynamic typing is different and shouldn’t be confused with Anonymous type.

7 :: Which is the tool which can convert Visual basic old version to .NET compatibility version?

There is a tool available which can convert old visual basic functions into new .NET code. Artin soft Visual basic upgrade Companion is very useful in converting VB code into .NET code. This tool was developed by Artin. This tool is integrated in Visual studio.NET 2005. It handles programs such as structured handling, error handling, etc.

8 :: What would you do to remove Microsoft visual basic name space?

.NET has many new features and application supportive tools. To remove Microsoft visual basic name space all you have to do is to
1) Remove the import manually every time you start the project.
2) Creating a template which does not contain Microsoft Visual Basic namespace.
3) About new features and changes names you can refer to MSDN.

9 :: Explain about the keyword Must Inherit?

This keyword prevents a class from directly instantiated. This keyword forces users to create references to only derived classes. This keyword is present in C# as abstract and it is very useful in creating applications.

10 :: Name some of the features of C# which are not present in VB.NET?

Some of the features which are not present in VB are as follows they are: -
1) It supports unsafe code blocks for improved performance.
2) Partial interfaces and anonymous methods.
3) Multi line comments and static classes. Etc

11 :: Name a feature which is common to all .NET languages?

There is only one feature which is common to all languages and that is Garbage collection or GC. This feature is automated which relieves developers of much work. This garbage is disposed only when there is need of memory or stress for memory. GC feature halts the application for few seconds before restarting it.

12 :: Name and explain some of the exclusive features which are present in VB?

Some of the features which are exclusive to VB are as follows: -
1) Name space can be hidden which can be disabled.
2) Certain project files can be hidden and a user can show them if he intends to do.
3) Lots and lots of shortcuts are present which ease the development of programs.
4) Using the AddressOf myObject function a delegate can be made.

13 :: Explain about Visual basic.NET culture?

VB was always a RAD tool and it was always user friendly for any type of user whether professional or not. It also provided many users with shortcuts and features which made this language popular among many users. It had its share of debugging and maintenance issues of course.

14 :: Compare C# and Visual basic.NET?

.NET Frame work includes two languages which are language to IL compilers and in this C# and VB.NET are provided. The importance and flexibility of these as better programming languages is still questionable. Visual basic has been updated and revised to make it object oriented whereas C# has concepts from many languages such as Delphi, Java, etc and syntax from C and Java.

15 :: Explain about the performance of Visual basic?

Visual basic 5 and 6 are efficient in coding the code to native or P-code depending upon the programmer. Portability is a major addition to the performance of VB.NET and the code is also small. Additional layer is provided which interprets the code and this can be avoided by using special algorithms and native code programming.

16 :: What are the various open source tool available for VB.NET?

When compared with the rapid development of open source tools for other languages from Microsoft (C#, etc) we can say that development of tools for VB has been slow. Mono development platform is one which is implementing VB libraries and is working on a compiler.

17 :: Describe about Visual basic.NET?

This is used in conjunction with Microsoft .NET platform and is a successor to visual basic sixth version. Visual basic is used in conjunction with.NET Framework. This tool has a serious defect it is not compatible with Microsoft visual basic sixth version. It has a huge library which assists programmers.

18 :: Explain and brief about rapid application development tool?

Rapid action development tool describes about the software development process. This tool gives flexibility in iterative development and prototype deployment. It enhances the speed of application development. It is also used for application maintenance.

19 :: Name some of the features present in VB 2005?

Some of the features present in VB 2005 are as follows: -
► Edit and continue: - It allows developers to modify and execute applications almost simultaneously.
► Namespace: - This provides access to various parts of the .NET framework and it also dynamically generates classes.
► Data source binding function is very useful for client server development.

20 :: Explain about .NET?

.NET is a Microsoft Framework and a software component. .NET has a large library of pre-coded solutions which provided developer significant help in developing applications with solutions already present. It offers reliable security and cross platform compatibility.

21 :: Explain about visual basic?

Visual basic is associated with the IDE of Microsoft. It is basically useful to implement RAD of GUI. Creation of Active X scripts are very easy and efficient through VB. Windows API can also be used to create application on windows desktop and its applications. This was primarily designed to create applications for windows platform.

22 :: How does the XmlSerializer work?

XmlSerializer in the .NET Framework is a great tool to convert Xml into runtime objects and vice versa
If you define integer variable and a object variable and a structure then how those will be plotted in memory.
Integer , structure - System.ValueType -- Allocated memory on stack , infact integer is primitive type recognized and allocated memory by compiler itself .
Infact , System.Int32 definition is as follows :

[C#]
[Serializable]
public struct Int32 : IComparable, IFormattable, IConvertible
So , it's a struct by definition , which is the same case with various other value types .
Object - Base class , that is by default reference type , so at runtime JIT compiler allocates memory on the "Heap" Data structure .
Reference types are defined as class , derived directly or indirectly by System.ReferenceType

23 :: What is a delegate, why should you use it and how do you call it ?

A delegate is a reference type that refers to a Shared method of a type or to an instance method of an object. Delegate is like a function pointer in C and C++. Pointers are used to store the address of a thing. Delegate lets some other code call your function without needing to know where your function is actually located. All events in .NET actually use delegates in the background to wire up events. Events are really just a modified form of a delegate.
It should give you an idea of some different areas in which delegates may be appropriate:
1.They enable callback functionality in multi-tier applications as demonstrated in the examples above.
2.The CacheItemRemoveCallback delegate can be used in ASP.NET to keep cached information up to date. When the cached information is removed for any reason, the associated callback is exercised and could contain a reload of the cached information.
3. Use delegates to facilitate asynchronous processing for methods that do not offer asynchronous behavior.
4.Events use delegates so clients can give the application events to call when the event is fired. Exposing custom events within your applications requires the use of delegates.

24 :: Where do you add an event handler?

It's the Attributesproperty, the Add function inside that property.
e.g. btnSubmit.Attributes.Add(""onMouseOver"",""someClientCode();"")

25 :: Why is it not a good idea to insert code into InitializeComponent method when working with Visual Studio?

The designer will likely through it away, most of the code inside InitializeComponent is auto-generated.
VB .Net Interview Questions and Answers
69 VB .Net Interview Questions and Answers