How to download Nanozip for windows?

You can download in this link:-


Q) How to archive the whole folder instead of a file?

Ans:-  For this Nano zip has an option for recursive archiving.

To compress:-

nz    a    -r   -cf    C:\Providethepathtothefolder\*





How to find the QT dependencies?or How to use Qt executables without installing QT?or Simply How to delpoy QT easily in windows?

This is very easy.

Note:- QT has a built in tool for deployment that finds out all the qt related dependencies once you run it.

**You can find the dependencies for either debug executable or release mode executable.


If you want debug mode executable to find its dependencies..

  1. Go the debug folder ….in my case this is the path in command prompt..

cd  C:\Users\Royal\Documents\test\debug

2) Now use this tool along with the executable

windeployqt.exe    test.exe

where test.exe is my debug mode executable after successful building.

You will generate  something like this..









ec…which depends on your project.


P.Note:-Sometimes the windeployqt.exe may not work …In that case search for the executable manually in the QT Folder..set the environment path ..then try again..





MS Visual c++ 6.0 :How to add Image/Logo or Icon to a button ?(MFC )


Follow these three steps:-

  1. Preparation of Image:-

a) Select the image.

b) Convert the image into bitmap format using Ms Paint or any other tool( it should be 256 color bit map).

      2. Adding the image into the bitmap resources of the project.

Go to resources tab in the workspace of the project.

In the Bitmap resources folder->right click and ->Insert->Select Bitmap then Import->select your bitmap image (take care of the type of file when searching).->import.

*** you can right click and change the ID of the resources.Lets say you renamed it to LOGO_BUTTON_ID


  3. Attach the images when required into the button.

—>lets load the bitmap first.

Bmp.LoadBitmap(LOGO_BUTTON_ID);//Now Bmp can be used as a variable whenever required in the program identifying the picture.

—>What about the button?Suppose the button ID is PUSH_BUTTON_ID

CButton *Button=(CButton*)GetDlgItem(PUSH_BUTTON_ID);//after this we ca use Button  to access the Push Button.

—>Attaching the Image to the button now..




If you want it to display the image as soon as the dialog opens then best way is to put the code in the  constructor of the dialog box  itself. 


MS visual c++ 6.0: Simple way to create and use a progress bar.

Its very simple !!.


In Visual c++ the built in class for progress bar is CProgresssCtrl.

You can create a pointer to the Progress_Bar object as shown:-

CProgressCtrl *ptr=(CProgressCtrl*) GetDlgItem(Progress_Bar);


Now whenever,

  1. You want to set the range  of the progress bar.Set in this way

ptr->SetRange(0,100);//means the range is from 0 to 100

2. If you want to set the size of each step or unit to be increased in the progress bar.


3. So how to cal the progress bar to step or increase ?

ptr->StepIt();//this will call the progress bar  to increase its step or change its step postion.

MS visual c++ 6.0(MFC): How to add a init constructor to the dialog class ?

In the  dialog.cpp file

include a code such as-

BOOL Dialog:OnInitDialog()


enter any constructor purpose code here


where Dialog is the name of that particular class.

Also a declaration has to be added to its .h(header file)

suppose dialog.h is the header file then,add these lines in the protected: portion of the class definition:-

virtual BOOL OnInitDialog();

Now you can add any of your constructor code inside the definition of initdialog.


Building Offline maps in QT without any server/Tile server ( Direct offline map using file protocol).

I went through lots of stuff for these and came to the conclusion that what I want is just as easy as it can be..;It was not necessary for me to create a tile server;  Therefore as I was searching for the easiest way to deal with offline maps in QT . Here is my answer that may help some ….

What is the Idea:-

  1. Generate tiles of the map for whatever zoom level you want. You can different software for this. Here I am using Maperative for generating tiles.


  1. Place the generated folder in any drive you want. These tiles will be accessed directly  through file protocol.

Now open an example project in QT called lightmaps .This is the exmaple  we are going to use.

Usually the path for these example is:-


or you can download here




go to slippymap.cpp

Inside slippymap.cpp  come to the bottom …to lines 215 /216..somewhere you should see..QString..

What to do now?

Here you replace the path  by the path of your tiles…for eg:- My tile location is D:\my_tiles

So here my String input will look like this..

     QString path = "file:///D:/my_tiles/%1/%2/%3.png";
be sure u dont mess up with the protocols..


IMPORTANT POINT.. you google and find out the location( latitude and longitude ) of the map you have downloaded first . These are required to display the exact location.We insert these  latitude,longitude and the zoom level in slippymap.cpp file in slippy map constructor (look to the top portion of the code).



Finally run the code.. It should display the map offline. These is a summary of what has been done..