Technicalsymposium



Join Our Email Alerts-Subscribe
Important Note:Login & Check Your Email Inbox and Activate Confirmation Link


Enter Your Email :

VC++ Materials-Free Download

Question 16. What Is Carchive Class Does? 

This class helps to do the serialization and de-serialisation. storing of objects from and to disk storage. The CArchive class allows user to save a complex objects to the permanent storage (usually disk storage) binary format. This objects persists after those objects are deleted. Later you can load the objects from permanent storage, reconstituting them in memory. 

• Question 17. What Is The Use Of Afx_manage_state ? 

MFC uses the resource handle of the main application to load the resource template. If you have an exported function in a DLL, such as one that launches a dialog box in the DLL, this template is actually stored in the DLL module. You need to switch the module state for the correct handle to be used. You can do this by adding the following code to the beginning of the function: AFX_MANAGE_STATE(AfxGetStaticModuleState( ));

This swaps the current module state with the state returned from AfxGetStaticModuleState until the end of the current scope. 

• Question 18. What Problem Does The Namespace Feature Solve? 

Multiple providers of libraries might use common global identifiers causing a name collision when an application tries to link with two or more such libraries. The namespace feature surrounds a library?s external declarations with a unique namespace that eliminates the potential for those collisions. 

• Question 19. Explain About Vc++?

Answer :

Microsoft visual C++ helps programmers and developers to create windows and .NET based applications. This also helps in developing applications for web, windows based applications, solutions for thin and smart client based mobile devices. It is used for developing applications for windows API, .NET framework, etc. 

• Question 20. Name Some Important Features Of Vc++?

Answer :

Some of the important features of VC++ are as follows:

1. Smart pointers

2. New containers

3. Expression parsing

4. Polymorphic function wrappers

5. Type traits and sophisticated random number generators.

• Question 21. What Is The Difference Between Struct And Class? 

There are few differences:

• All members of struct are public.

• Default inheritance for struct is public, where as for class the default inheritance is private. 

Q:- What is thread & process?

Ans:- Threads are similar to processes, but differ in the way that they share resources. Threads are distinguished from processes in that processes are typically independent, carry considerable state information and have separate address spaces. Threads typically share the memory belonging to their parent process. 

Q:- what is the use of AFX_MANAGE_STATE ?

Ans:- By default, MFC uses the resource handle of the main application to load the resource template. If you have an exported function in a DLL, such as one that launches a dialog box in the DLL, this template is actually stored in the DLL module. You need to switch the module state for the correct handle to be used. You can do this by adding the following code to the beginning of the function: 

AFX_MANAGE_STATE(AfxGetStaticModuleState( ));

This swaps the current module state with the state returned from AfxGetStaticModuleState until the end of the current scope. If all your resources lies in the single DLL you can even change the default handle to the DLL handle with the help of AfxSetResourceHandle function. 

Q:- Why wizards generate enum IDD for dialogs?

Ans:- It's good programming practice to do it this way, as from the client code you can always refer to the CMyDlg::IDD without worrying what the actual constant is. 

Q:- What is CArchive class does?

Ans:- The CArchive class allows you to save a complex network of objects in a permanent binary form (usually disk storage) that persists after those objects are deleted. Later you can load the objects from persistent storage, reconstituting them in memory. This process of making data persistent is called “serialization.”

Source: Contents are provided by Technicalsymposium Google Group Members. 
Disclaimer: All the above contents are provided by technicalsymposium.com Google Group members. 
Further, this content is not intended to be used for commercial purpose. Technicalsymposium.com is not liable/responsible for any copyright issues.


Technicalsymposium.com-Download All Technical Interview Materials