简体   繁体   中英

get default Windows text editor .exe path using c++

Just wanted to know how to get default Windows text editor .exe path c++. I badly need this to improve one of my c++ assignment. I've no idea how to do it.

If you require it to open files, then you can use ShellExecute with the edit (or open ) verb to get everything done all-in-one, else you can use SHAssocEnumHandlers to get the handlers for the text based files you are interested in.

In the most simple case, you can also use %windir%\\\\notepad.exe which will link to notepad on any desktop version of windows.

通常的方法是使用FindExecutable

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM