Click here to Skip to main content
15,917,481 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: MySQL help!!! Pin
Nish Nishant10-Dec-01 20:16
sitebuilderNish Nishant10-Dec-01 20:16 
GeneralXML Schema (xmlspy<=>msxml) Pin
10-Dec-01 4:53
suss10-Dec-01 4:53 
GeneralTab order Pin
andysolman10-Dec-01 4:48
andysolman10-Dec-01 4:48 
GeneralRe: Tab order Pin
Ravi Bhavnani10-Dec-01 4:52
professionalRavi Bhavnani10-Dec-01 4:52 
GeneralRe: Tab order Pin
andysolman10-Dec-01 23:54
andysolman10-Dec-01 23:54 
GeneralRe: Tab order Pin
Ravi Bhavnani11-Dec-01 1:53
professionalRavi Bhavnani11-Dec-01 1:53 
GeneralCreateProcess Pin
HF10-Dec-01 4:30
HF10-Dec-01 4:30 
GeneralRe: CreateProcess Pin
Jon Hulatt10-Dec-01 5:18
Jon Hulatt10-Dec-01 5:18 
Try this. You ought to specify the executable name in first arg of createprocess, and use the second solely for your arguments.

Also, Virtually everything in CreateProcess is nullable. Including the last arg, for process information. But i included that since it looks like you wanted a process handle.

Jon

HANDLE LanceProcess(CString nom_fic_exec,CString paramstring)
{
      BOOL bStatus; PROCESS_INFORMATION PI;
      CString strProcess = nom_fic_exec;
      CString strCommandLine=paramstring;

      bStatus=CreateProcess( (LPCSTR) strProcess,
                     (LPTSTR) strCommandLine.GetBuffer(MAX_PATH),
                     NULL,
                     NULL,
                     TRUE,
                     NORMAL_PRIORITY_CLASS,
                     NULL,
                     NULL,
                     NULL,
                     &PI );
       if (!bStatus)
          AfxMessageBox("your error message);

       return PI.hProcess;
}










Sorry to dissapoint you all with my lack of a witty or poignant signature.
GeneralRe: CreateProcess Pin
HF12-Dec-01 0:06
HF12-Dec-01 0:06 
GeneralRe: CreateProcess Pin
HF12-Dec-01 3:26
HF12-Dec-01 3:26 
GeneralRe: CreateProcess Pin
Lim Bio Liong12-Dec-01 18:36
Lim Bio Liong12-Dec-01 18:36 
GeneralRe: CreateProcess Pin
HF13-Dec-01 3:47
HF13-Dec-01 3:47 
GeneralRe: CreateProcess Pin
Lim Bio Liong13-Dec-01 19:40
Lim Bio Liong13-Dec-01 19:40 
GeneralNon Client Painting Pin
Jon Hulatt10-Dec-01 4:29
Jon Hulatt10-Dec-01 4:29 
GeneralRe: Non Client Painting Pin
Ravi Bhavnani11-Dec-01 5:28
professionalRavi Bhavnani11-Dec-01 5:28 
GeneralCropping A DIB Pin
AJ12310-Dec-01 3:24
AJ12310-Dec-01 3:24 
GeneralRe: Cropping A DIB Pin
Chris Losinger10-Dec-01 4:35
professionalChris Losinger10-Dec-01 4:35 
GeneralMySQL HELP! Pin
Bill Gates Antimatter Particle10-Dec-01 1:43
Bill Gates Antimatter Particle10-Dec-01 1:43 
GeneralRe: MySQL HELP! Pin
Jon Hulatt10-Dec-01 4:30
Jon Hulatt10-Dec-01 4:30 
GeneralPrinting bitmap fails, but preview ok Pin
9-Dec-01 23:24
suss9-Dec-01 23:24 
GeneralRe: Printing bitmap fails, but preview ok Pin
Ravi Bhavnani10-Dec-01 4:14
professionalRavi Bhavnani10-Dec-01 4:14 
GeneralRe: Printing bitmap fails, but preview ok Pin
11-Dec-01 2:34
suss11-Dec-01 2:34 
GeneralRe: Printing bitmap fails, but preview ok Pin
11-Dec-01 4:03
suss11-Dec-01 4:03 
GeneralRe: Printing bitmap fails, but preview ok Pin
Chris Losinger11-Dec-01 4:19
professionalChris Losinger11-Dec-01 4:19 
GeneralData binding with grid control Pin
imranqau9-Dec-01 21:37
imranqau9-Dec-01 21:37 

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.