Click here to Skip to main content
15,905,963 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: How to add a file to an application Pin
Iain Clarke, Warrior Programmer21-Feb-08 1:29
Iain Clarke, Warrior Programmer21-Feb-08 1:29 
GeneralFile Rename Problem Pin
john563220-Feb-08 19:28
john563220-Feb-08 19:28 
GeneralRe: File Rename Problem Pin
Maxwell Chen20-Feb-08 19:44
Maxwell Chen20-Feb-08 19:44 
GeneralRe: File Rename Problem Pin
john563220-Feb-08 19:57
john563220-Feb-08 19:57 
GeneralRe: File Rename Problem Pin
Maxwell Chen20-Feb-08 21:50
Maxwell Chen20-Feb-08 21:50 
GeneralRe: File Rename Problem Pin
john563220-Feb-08 20:04
john563220-Feb-08 20:04 
GeneralRe: File Rename Problem Pin
Maxwell Chen20-Feb-08 21:35
Maxwell Chen20-Feb-08 21:35 
GeneralCreateProcess() not working Pin
tony_Udz20-Feb-08 18:19
tony_Udz20-Feb-08 18:19 
Hello,

Can you please help me understand CreateProcess() function.
I am new to this concept.
Syntax of CreateProcess() is: -

BOOL CreateProcess(
PCTSTR pszApplicationName,
PTSTR pszCommandLine,
PSECURITY_ATTRIBUTES psaProcess,
PSECURITY_ATTRIBUTES psaThread,
BOOL bInheritHandles,
DWORD fdwCreate,
PVOID pvEnvironment,
PCTSTR pszCurDir,
PSTARTUPINFO psiStartInfo,
PPROCESS_INFORMATION ppiProcInfo);


My Code snippet is: -

STARTUPINFO si = { sizeof(si) };
PROCESS_INFORMATION pi;

TCHAR szPath[] = TEXT("C:\\Documents and Settings\\abhishekc\\Desktop\\code.txt");

bool bIsProcessCreated = CreateProcess(TEXT("c:\\windows\\SYSTEM32\\notepad.exe"),szPath,NULL, NULL,FALSE, 0,
NULL, NULL, &si, &pi);


Output: -
A new Notepad file opens and dialog pop-up "The System cannot find the specified path".

====================================================================================

All the path provided are true.
CreateProcess() returns true.
I am confused among two parameters of CreateProcess() viz: PCTSTR pszApplicationName,
PTSTR pszCommandLine.

Thanks in advance.
GeneralRe: CreateProcess() not working [modified] Pin
Maxwell Chen20-Feb-08 18:39
Maxwell Chen20-Feb-08 18:39 
GeneralRe: CreateProcess() not working Pin
tony_Udz20-Feb-08 19:09
tony_Udz20-Feb-08 19:09 
GeneralRe: CreateProcess() not working Pin
Rajkumar R20-Feb-08 20:38
Rajkumar R20-Feb-08 20:38 
GeneralEmbedding vlc player in to the application Pin
Chandrasekharan P20-Feb-08 17:32
Chandrasekharan P20-Feb-08 17:32 
GeneralTo embed a word document into a C++ console based exe Pin
Mushtaque Nizamani20-Feb-08 17:26
Mushtaque Nizamani20-Feb-08 17:26 
QuestionRe: To embed a word document into a C++ console based exe Pin
Rajkumar R20-Feb-08 18:07
Rajkumar R20-Feb-08 18:07 
GeneralRe: To embed a word document into a C++ console based exe Pin
Maxwell Chen20-Feb-08 19:05
Maxwell Chen20-Feb-08 19:05 
QuestionA problem when you press ESC in a CEdit ctrl Pin
zengkun10020-Feb-08 16:05
zengkun10020-Feb-08 16:05 
GeneralRe: A problem when you press ESC in a CEdit ctrl Pin
Maxwell Chen20-Feb-08 16:20
Maxwell Chen20-Feb-08 16:20 
GeneralRe: A problem when you press ESC in a CEdit ctrl Pin
zengkun10020-Feb-08 16:39
zengkun10020-Feb-08 16:39 
GeneralRe: A problem when you press ESC in a CEdit ctrl Pin
Maxwell Chen20-Feb-08 16:44
Maxwell Chen20-Feb-08 16:44 
QuestionHow to access Blu-ray discs' video file? Pin
kcynic20-Feb-08 14:54
kcynic20-Feb-08 14:54 
GeneralFunny symbols Reading Registry Key Values Pin
J_E_D_I20-Feb-08 10:14
J_E_D_I20-Feb-08 10:14 
QuestionRe: Funny symbols Reading Registry Key Values Pin
David Crow20-Feb-08 10:43
David Crow20-Feb-08 10:43 
GeneralRe: Funny symbols Reading Registry Key Values Pin
Mark Salsbery20-Feb-08 13:19
Mark Salsbery20-Feb-08 13:19 
GeneralRe: Funny symbols Reading Registry Key Values Pin
Mark Salsbery20-Feb-08 13:23
Mark Salsbery20-Feb-08 13:23 
GeneralRe: Funny symbols Reading Registry Key Values Pin
J_E_D_I21-Feb-08 21:31
J_E_D_I21-Feb-08 21:31 

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.