Click here to Skip to main content
15,916,019 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: what's function? Pin
led mike28-Jun-07 9:21
led mike28-Jun-07 9:21 
GeneralRe: what's function? Pin
Adno28-Jun-07 9:44
Adno28-Jun-07 9:44 
AnswerRe: what's function? [modified] Pin
led mike28-Jun-07 9:23
led mike28-Jun-07 9:23 
GeneralRe: what's function? Pin
Mark Salsbery28-Jun-07 11:16
Mark Salsbery28-Jun-07 11:16 
Questioncall main view form subclass Pin
Tara1428-Jun-07 5:41
Tara1428-Jun-07 5:41 
AnswerRe: call main view form subclass Pin
Matthew Faithfull28-Jun-07 6:27
Matthew Faithfull28-Jun-07 6:27 
GeneralRe: Yipeeeee! Pin
Tara1428-Jun-07 17:27
Tara1428-Jun-07 17:27 
QuestionUsing ShellExecute to launch notepad ??? Pin
ldsdbomber28-Jun-07 5:14
ldsdbomber28-Jun-07 5:14 
I've snagged this to open a helpfile for an MFC dialog. For now, it's OK to be just a text file, though at some point an integrated help file / CHM might be better

ShellExecute(this->m_hWnd,"open","notepad.exe","PTW Geske Analyse Help.txt","",SW_SHOW );


Problem is, I am not sure what the paths are involved. It opens notepad correctly but it is not finding the text file. I tried putting it in the same folder as the executable that's launching notepad but to no avail. How can I use a relative path so that if I distribute the program exe and the help file and state that they should be in the same folder, then notepad will correctly find the text file

t.i.a

Lee

ps
have seen ShellExecuteEx but it seemed the extra info (incl. path) refers to the path for notepad and not the target file


PS
it seems to be defaulting to desktop since thats where it saves a new file if promptedm and when I put the txt file there it does indeed open it. Perhaps I need a SetPath type instruction, but I want it to be relative to the running program and not a hard coded path.
AnswerRe: Using ShellExecute to launch notepad ??? Pin
Mark Salsbery28-Jun-07 7:07
Mark Salsbery28-Jun-07 7:07 
GeneralRe: Using ShellExecute to launch notepad ??? Pin
ldsdbomber28-Jun-07 23:30
ldsdbomber28-Jun-07 23:30 
AnswerRe: Using ShellExecute to launch notepad ??? Pin
toxcct28-Jun-07 7:19
toxcct28-Jun-07 7:19 
GeneralRe: Using ShellExecute to launch notepad ??? Pin
ldsdbomber28-Jun-07 23:31
ldsdbomber28-Jun-07 23:31 
QuestionTime and Date Pin
mcsherry28-Jun-07 5:05
mcsherry28-Jun-07 5:05 
Questionscrollbars Pin
Adno28-Jun-07 4:37
Adno28-Jun-07 4:37 
Questionunions and their methods... Pin
zqueezy28-Jun-07 4:24
zqueezy28-Jun-07 4:24 
AnswerRe: unions and their methods... Pin
CPallini28-Jun-07 5:11
mveCPallini28-Jun-07 5:11 
Questionhide java errors/warnings in webbrowser control [modified] Pin
awah28-Jun-07 3:59
awah28-Jun-07 3:59 
QuestionTaking in the string selected from the combo box and then using it for further tasks Pin
lovneet28-Jun-07 3:09
lovneet28-Jun-07 3:09 
AnswerRe: Taking in the string selected from the combo box and then using it for further tasks Pin
CPallini28-Jun-07 3:26
mveCPallini28-Jun-07 3:26 
GeneralRe: Taking in the string selected from the combo box and then using it for further tasks Pin
lovneet28-Jun-07 19:23
lovneet28-Jun-07 19:23 
Questionturning off tab stop for some items Pin
ldsdbomber28-Jun-07 2:45
ldsdbomber28-Jun-07 2:45 
AnswerRe: turning off tab stop for some items Pin
toxcct28-Jun-07 2:47
toxcct28-Jun-07 2:47 
GeneralRe: turning off tab stop for some items Pin
ldsdbomber28-Jun-07 3:51
ldsdbomber28-Jun-07 3:51 
Questionadd reference to visual c++ Pin
djdjoko28-Jun-07 2:34
djdjoko28-Jun-07 2:34 
QuestionRe: add reference to visual c++ Pin
Hamid_RT28-Jun-07 4:00
Hamid_RT28-Jun-07 4:00 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.