Click here to Skip to main content
15,896,111 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi,

I want to Save and Open the files in VC++ 6.0.
For ex:When ever i Click on Save button it has to display one window as same as in Ms-word save option. Open option also same as in Ms-word.

Can Anyone help me.


Thanks
Posted

You can use CFileDialog for this purpose.

Check this example on CFileDialog,

CFileDialog Example
 
Share this answer
 
Comments
Joan M 21-Jun-11 4:17am    
Nice and easy! ;) 5ed.
Albert Holguin 21-Jun-11 9:27am    
that easy... 5
Using CFileDialog as venkatmakam suggest is the way to go.

Anyway, that dialog will only help you to navigate to the right folder and to select the file name, just after that you will need to make all the operations that you want to do:


A) save files using your preferred method, serializing, writing directly to disk (fopen, fwrite...) or any other method...

or

B) read the file from disk... and of course then you will need to show the contents into your application.

Good luck!
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900