Opening a File Help

Ok, so I'm pretty new to c++, so Ive decided to just make a quick text adventure in cmd to practice and learn to code. Ive already got most of the basic code and stuff, but I was wondering if there's a way to open a file with c++. What I want to do is at certain points, open an image file that's located in the folder with the .exe file with whatever is the default image viewer for the computer. I know its more practical to not use cmd for this, but I would still like to know how to do this.
If you want to "launch" or "open" a file with the default program for that file, then read about ShellExecute(). Not sure if C++'s system() command would work too, but the Windows way is ShellExecute(). Of course, that would mean working with the Windows SDK and I don't know if you have ever done it.
Topic archived. No new replies allowed.