[Last Call] Learn about multicloud storage options and how to improve your company's cloud strategy. Register Now

x
?
Solved

Opening a File with Notepad from VC++

Posted on 2003-11-05
3
Medium Priority
?
242 Views
Last Modified: 2013-11-20
Hi ,
I want to open a file in Notepad on a Event in VC++ .
At present i am using system() command to achive this.
But the command window is also being displayed with the
Notepad . I don't want the command window to be displayed
how do i achive this..
Regards
Dev
0
Comment
Question by:moonoo
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 86

Expert Comment

by:jkr
ID: 9691586
Hum, the easiest way (if it is a .txt file) would be to

ShellExecute ( NULL, "open", "myfile.txt", NULL, NULL, SW_SHOW);
0
 
LVL 86

Accepted Solution

by:
jkr earned 500 total points
ID: 9691597
BTW, if you want to enforce the usage of notepad if it is a file not registered with it,

ShellExecute ( NULL, "open", "notepad.exe", "myfile.sth", NULL, SW_SHOW);

would work also.

0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this article, I'll describe -- and show pictures of -- some of the significant additions that have been made available to programmers in the MFC Feature Pack for Visual C++ 2008.  These same feature are in the MFC libraries that come with Visual …
In this post we will learn different types of Android Layout and some basics of an Android App.
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
In this video you will find out how to export Office 365 mailboxes using the built in eDiscovery tool. Bear in mind that although this method might be useful in some cases, using PST files as Office 365 backup is troublesome in a long run (more on t…

650 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question