Sunday, 31 July 2011

Multithreading MFC Part-I

Part I of this tutorial covers basic concept of multithreading. If you have never used multithreading in your application and wish to know how to use multithreading in your applications and why, Then this article might be useful for you. I will cover samples and advanced topics of multithreading in the Part II of this tutorial.Threading Concepts:A thread is a path of execution. Each application has a default thread called 'Main Thread' or 'PrimaryThread'. You can create multiple threads in your program. Other threads besides primary threads are called'Secondary Threads'. Each process has at least one of more threads.Multithreading:Running more than one thread simultaneously is multithreading.Why multiple threads?Sometimes your program requirement is to do more than one task simultaneously....

COM Interview

IntroductionWhat is IUnknown? What methods are provided by IUnknown? It is a generally good idea to have an answer for this question if you claim you know COM in your resume. Otherwise, you may consider your interview failed at this point. IUnknown is the base interface of COM. All other interfaces must derive directly or indirectly from IUnknown. There are three methods in that interface: AddRef, Release and QueryInterface. What are the purposes of AddRef, Release and QueryInterface functions? AddRef increments reference count of the object, Release decrements reference counter of the object and QueryInterface obtains a pointer to the requested...

Saturday, 30 July 2011

Windows Data Types

Windows Data TypesThe data types supported by Windows are used to define function return values, function and message parameters, and structure members. They define the size and meaning of these elements. For more information about the underlying C/C++ data types, see Data Type Ranges.The following table contains the following types: character, integer, Boolean, pointer, and handle. The character, integer, and Boolean types are common to most C compilers. Most of the pointer-type names begin with a prefix of P or LP. Handles refer to a resource that has been loaded into memory.For more information about handling 64-bit integers, see Large Integers.Data typeDescriptionAPIENTRYThe calling convention for system functions.This type is declared in WinDef.h as follows:#define...

VC++ Interview Part - 1

Starting point of windows application?WinMain() is the entry point of Windows applications.Parameters of WinMain()int WINAPI WinMain (HINSTANCE hInstance, HINSTANCE hPrevInstance,LPSTR lpszCmdLine, int nCmdShow)hInstance – The handle of the currently running module.hPrevInstance – A handle to a previous instance of the application. For a Win32-based application, this parameter is always NULL.lpCmdLine – Points to a null-terminated string specifying the command line for the application.nCmdShow – Specifies how the main window of a GUI application would be shown.What is windows programming? How it’s working?Windows is an event driven programming mechanism, in which applications respond to events by processing messages sent by the operating system. An event could be a keystroke, a mouse...
Page 1 of 3412345Next

Popular Posts

 
Design by Free WordPress Themes | Bloggerized by Lasantha - Premium Blogger Themes | cheap international calls