C++ COM ActiveX

  Home  C++ Programming  C++ COM ActiveX


“C++ COM ActiveX frequently Asked Questions by expert members with experience in C++ COM ActiveX. These questions and answers will help you strengthen your technical skills, prepare for the new job test and quickly revise the concepts”



22 C++ COM ActiveX Questions And Answers

1⟩ What is object serialization?

A serialized object represents the type of data stored in the object, its information. Object serialization is a process of reading or writing an entire object from a file. This helps in saving session state information by servlets, for sending parameters for Remote Method Invocation (RMI) calls.

 200 views

2⟩ What is OLE?

Object Linking and Embedding (OLE) is about using documents generated by one application inside another application.

 187 views

3⟩ What is STL, standard template library?

The Standard Template Library, or STL, is a C++ library of container classes, algorithms, and iterators; it provides many of the basic algorithms and data structures

The STL includes the classes vector, list, deque, set, multiset, map, multimap, hash_set, hash_multiset, hash_map, and hash_multimap.

 188 views

4⟩ What is ActiveX?

ActiveX is a Microsoft rebranding of OLE with more focus on smart Windows controls.

 177 views

5⟩ What is IUnknown interface?

The IUnknown interface lets clients get pointers to other interfaces on a given object through the QueryInterface method, and manage the existence of the object through the IUnknown::AddRef and IUnknown::Release methods.

IUnknown methods can be used to switch between interfaces on an object, add references, and release objects.

You must implement IUnknown as part of every interface.

 201 views

6⟩ Do you know what is a type library?

A file or component within another file that contains standard descriptions of exposed objects, properties, and methods

A type library contains a binary description of an interface exposed by a COM-component. In this sense, they contain the same information that is contained in an IDL (Interface Definition Language) file..

 189 views

7⟩ Tell me how does COM provide language transparency?

COM defines an API to allow for the creation of components for use in integrating custom applications or to allow diverse components to interact.

But in order to interact, components must adhere to a binary structure specified by Microsoft.

As long as components adhere to this binary structure, components written in different languages can interoperate.

 189 views

8⟩ What is Component Object Model?

COM defines an API to allow for the creation of components for use in integrating custom applications or to allow diverse components to interact.

But in order to interact, components must adhere to a binary structure specified by Microsoft.

As long as components adhere to this binary structure, components written in different languages can interoperate.

 179 views

9⟩ What is Globally Unique Identifier?

A 16-byte number generated by Microsoft programs that uniquely identifies a network or user or computer or document. It is one of the elements of information that can be passed when you connect to an Internet site, and it may be stored in cookies

 176 views

10⟩ Explain dual interfaces?

A dual interface allows its methods to be accessed as dispinterface methods or as vtable methods.

Dual interface is one that supports both - IDispatch interface and vtbl-based interface. Therefore, it might be used in scripting environment like VBScript and yet to use power and speed of vtbl-based interface for non-scripting environment.

 197 views

11⟩ Explain GUID?

GUID stands for Globally Unique Identifier.

A 16-byte number generated by Microsoft programs that uniquely identifies a network or user or computer or document. It is one of the elements of information that can be passed when you connect to an Internet site, and it may be stored in cookies.

 196 views

12⟩ Explain shallow and deep copy?

A shallow copy just copies the values of the data as they are. Even if there is a pointer that points to dynamically allocated memory, the pointer in the copy will point to the same dynamically allocated.

 184 views

13⟩ Explain type library?

A file or component within another file that contains standard descriptions of exposed objects, properties, and methods

A type library contains a binary description of an interface exposed by a COM-component. In this sense, they contain the same information that is contained in an IDL (Interface Definition Language) file.

 198 views

14⟩ Define STL, standard template library?

STL contains classes, algorithms, and iterators. It contains set of ready to use C++ classes that can be used with built in type and user defined operations. STL uses templates to achieve the results.

 187 views

15⟩ Explain object serialization?

A serialized object represents the type of data stored in the object, its information. Object serialization is a process of reading or writing an entire object from a file. This helps in saving session state information by servlets, for sending parameters for Remote Method Invocation (RMI) calls.

 191 views

16⟩ Why does COM need GUIDs?

A globally unique identifier (GUID) is used for unique IDs. No two GUIDs are the same no matter what computer they were generated on. The attribute clsid defines the GUID of the associated ActiveX control to use.

 194 views

17⟩ Explain ActiveX and OLE?

Object Linking and Embedding (OLE) is about using documents generated by one application inside another application.

ActiveX is a Microsoft rebranding of OLE with more focus on smart Windows controls.

 187 views

18⟩ Define the syntax and semantics for a function template?

Templates is one of the features of C++. Using templates, C++ provides a support for generic programming.

We can define a template for a function that can help us create multiple versions for different data types.

A function template is similar to a class template and it syntax is as follows:

template <class T>

Return-type functionName (arguments of type T)

{

//Body of function with type T wherever appropriate

}

 179 views

19⟩ Explain Component Object Model?

COM defines an API to allow for the creation of components for use in integrating custom applications or to allow diverse components to interact.

But in order to interact, components must adhere to a binary structure specified by Microsoft.

As long as components adhere to this binary structure, components written in different languages can interoperate.

 185 views

20⟩ How COM provide the language transparency?

COM defines an API to allow for the creation of components for use in integrating custom applications or to allow diverse components to interact.

But in order to interact, components must adhere to a binary structure specified by Microsoft.

As long as components adhere to this binary structure, components written in different languages can interoperate.

 184 views