VB .Net

  Home  Microsoft .Net Technologies  VB .Net


“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

24⟩ What is the significance of delegates. Where should they be used? What are the situations where we require them?

Delegates are used as pointer to hold the controls actually i used the delegates when there is problem in VB.Net 2005 where each control is already threaded, to use my personla thread on these control i used delegates

Ex:

Private Delegate Sub dd()

Dim d1 As New dd(AddressOf c1)

Dim t1 As New Threading.Thread(AddressOf thread1)

public sub Thread1()

r1 =

Me.Label1.BeginInvoke(d1)

Me.Label1.EndInvoke(r1)

end sub

Public Sub c1()

Me.Label1.Text = ct1

Me.Label1.Refresh()

End Sub

 178 views

30⟩ In vb.net how to connect crystal report?

Click on solution explorer window right click and add to add new item. The window will be displaced select

the crystal reports we have save in any name but extension is used .rpt eg:sss.rpt

 167 views

31⟩ Explain the differences between Server-side and Client-side code?

Server side code executes on the server.For this to occur page has to be submitted or posted back.Events fired by the controls are executed on the server.Client side code executes in the browser of the client without submitting the page.

e.g. In ASP.NET for webcontrols like asp:button the click event of the button is executed on the server hence the event handler for the same in a part of the code-behind (server-side code). Along the server-side code events one can also attach client side events which are executed in the clients browser i.e. javascript events.

 155 views

32⟩ How would you implement inheritance using VB.NET/C#?

When we set out to implement a class using inheritance, we must first start with an existing class from which we will derive our new subclass. This existing class, or base class, may be part of the .NET system class library framework, it may be part of some other application or .NET assembly, or we may create it as part of our existing application. Once we have a base class, we can then implement one or more subclasses based on that base class. Each of our subclasses will automatically have all of the methods, properties, and events of that base class ? including the implementation behind each method, property, and event. Our subclass can add new methods, properties, and events of its own - extending the original interface with new functionality. Additionally, a subclass can replace the methods and properties of the base class with its own new

implementation - effectively overriding the original behavior and replacing it with new behaviors. Essentially inheritance is a way of merging functionality from an existing class into our new subclass. Inheritance also defines rules for how these methods, properties, and events can be merged. In VB.NET we can use implements keyword for inheritance, while in C# we can use the sign ( :: ) between subclass and baseclass.

 151 views

34⟩ What does it meant to say "the canonical" form of XML?

"The purpose of Canonical XML is to define a standard format for an XML document. Canonical XML is a very strict XML syntax, which lets documents in canonical XML be compared directly.

Using this strict syntax makes it easier to see whether two XML documents are the same. For example, a section of text in one document might read Black & White, whereas the same section of text might read Black & White in another document, and even in another. If you compare those three documents byte by byte, they'll be different. But if you write them all in canonical XML, which specifies every aspect of the syntax you can use, these three documents would all have the same version of this text (which would be Black & White) and could be compared without problem.

This Comparison is especially critical when xml documents are digitally signed. The digital signal may be interpreted in different way and the document may be rejected.

 152 views

35⟩ Why is the XML InfoSet specification different from the Xml DOM? What does the InfoSet attempt to solve?

"The XML Information Set (Infoset) defines a data model for XML. The Infoset describes the abstract representation of an XML Document. Infoset is the generalized representation of the XML Document, which is primarily meant to act as a set of definitions used by XML technologies to formally describe What parts of an XML document they operate upon.

The Document Object Model (DOM) is one technology for representing an XML Document in memory and to programmatically read, modify and manipulate a xml document.

Infoset helps defining generalized standards on how to use XML that is not dependent or tied to a particular XML specification or API. The Infoset tells us What part of XML Document should be considered as significant information.

 186 views

36⟩ Whats the difference between const and readonly?

The readonly keyword is different from the const keyword. A const field can only be initialized at the declaration of the field. A readonly field can be initialized either at the declaration or in a constructor. Therefore, readonly fields can have different values depending on the constructor used. Also, while a const field is a compile-time constant, the readonly field can be used for runtime constants as in the following example:

public static readonly uint l1 = (uint) DateTime.Now.Ticks;

 171 views