Interview
Interview
ANS 4 - Arrays does not provide built-in functions like add(),remove(),removeAt(),insert(),and many more.
but arraylist provides all above.
The super most base class is system.object. even the system.web.ui comes from the system.object. All
the object of type either value or reference type come from system.object. see the msdn doc for the
same.
3- How to store and retrieve images in SQL server database through VB.NET?
To store images in Sql Database you need to set the field to image in sql server then you have to
convert image to binary and then save to database location.
In vb.net, the images can be stored into database in the form of ByteArray.At the time of retrieving,we
can assign the byteArray to MemoryStream and then convert into image.
String is mutable means if we want to add something at the end of string then first it will remove that
string then it will write desired string.
String builder is immutable means while adding one more char at the end of string it directly upend the
string without remove original string.
5- Differences between VB.Net and C#, related to OOPS concepts
The Finalize method is actually executed by the runtime on a special thread allocated by the Garbage
Collector (GC).The Finalize method is executed whenever the runtime feels it is appropriate, such as when a
low-resource condition occurs and this situation is often referred to as non-deterministic finalization.
Garbage collection is the mechanism to release memory allocated by a objects / Veriables which are
no longer exists in programme.
In .NET Framework, garbage collector is implemented as a separate thread. This thread will always be
running at the back end. Since garbage collector always run at the back end there will be extra overhead for
the memory. Therefore garbage collector is given the lowest priority in .NET Framework. In .NET
Framework, garbage collection system is based on the Mark and Compact algorithm that involves removing
of objects that have gone out of scope and compacts all the remaining objects at the beginning of the address
space. The space allotted for the application is also referred to as managed heap. When a new object needs to
be instantiated and if there is not enough room in the application?s managed heap, the garbage collection
process starts.
we can create a read only property by using the keyword "Read only" before the syntax .e.g
Read only property Property_name([args]) as type get [statement]
end get
end property
10- What is .net?
.Net is the Development Platform which provides advanced feature facilities for the web and window
application along with the window services . The .Net is the Middle layer between the operating System and
the .Net application .The feature of .Net that the .Net Component can talk with each other without worrying
about the language in which they are originally.. Two main components are CLR stands for the common
Language Runtime and the .Net FrameWork Base classes. The CLR performs the task of converting the IL to
native code Which gives the .Net applications to be language Independent . The Other component Like .Net
FramwWork Base Classes act as services to be provided to the .Net applications.
11- How VB Implements the Disonnected Architecture as like VB.Net?
In VB to implement a disconnected recordset, after you have filled the recordset with the data, set its
active connection property to "Nothing". That breaks the connection to the database.You can locally also save
the data of the recordset by using its Save function.
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.
Console Applications have only recently been introduced in VB (Excluding VB for DOS).
They are command line based and run in within a DOS Shell (DOS Window). Unlike Windows Applications,
Console Applications do not support Windows GUI's. Which means that you can't work with controls from
the toolbox.
To work with Console Applications select File->New->Project and in selected "Console Application" from
the template under Visual Basic or Visual C#.
Module Module 1
Sub Main ()
System.Console.WriteLine ("Hello World?)
End Sub
End Module
14- Whats the difference bt. .dll extension and .exe extension files?
.dll is the In process component where it take up the client's memory space to run. So the
communication between the application and component(dll) is very fast.
.EXE is the Out of process component. It uses its own memory(not application memory) to run the
component. The communication between the application and component is slow when compared to .dll
15- What is the source code for display the picture in button click event?
PictureBox1.Image = Image.FromFile("C:olympics08_basketball.gif")
16-