Open a file in Notepad from VC++ Application

P

preetish

Hi,

I am a total novice to VC++..I have a dialog based application
developed using MFC...my requirement is to open a file (with .dat or
..txt ext) invoking Notepad from my application. The user should be able
to pick the file from the list and then on hit of the Open button it
should open the file in notepad. I am not able to figure out how to
invoke notepad passing the filename from on my OPEN button click.
 
T

thatsalok

*Hi,

I am a total novice to VC++..I have a dialog based application
developed using MFC...my requirement is to open a file (with .dat or
...txt ext) invoking Notepad from my application. The user should b
able
to pick the file from the list and then on hit of the Open button it
should open the file in notepad. I am not able to figure out how to
invoke notepad passing the filename from on my OPEN button click. *

What About using CreateProcess or ShellExecute api

eg

Code
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top