請問有關ShellExecute的問題 |
答題得分者是:Justmade
|
lin11112
初階會員 發表:42 回覆:83 積分:25 註冊:2003-02-17 發送簡訊給我 |
|
Justmade
版主 發表:94 回覆:1934 積分:2030 註冊:2003-03-12 發送簡訊給我 |
var ReturnValue : integer; ReturnValue := ShellExecute(....); Return Value 的錯誤 Wind32 SDK Help 有介紹啊 :
0 The operating system is out of memory or resources. ERROR_FILE_NOT_FOUND The specified file was not found. ERROR_PATH_NOT_FOUND The specified path was not found. ERROR_BAD_FORMAT The .EXE file is invalid (non-Win32 .EXE or error in .EXE image). SE_ERR_ACCESSDENIED The operating system denied access to the specified file. SE_ERR_ASSOCINCOMPLETE The filename association is incomplete or invalid. SE_ERR_DDEBUSY The DDE transaction could not be completed because other DDE transactions were being processed. SE_ERR_DDEFAIL The DDE transaction failed. SE_ERR_DDETIMEOUT The DDE transaction could not be completed because the request timed out. SE_ERR_DLLNOTFOUND The specified dynamic-link library was not found. SE_ERR_FNF The specified file was not found. SE_ERR_NOASSOC There is no application associated with the given filename extension. SE_ERR_OOM There was not enough memory to complete the operation. SE_ERR_PNF The specified path was not found. SE_ERR_SHARE A sharing violation occurred.約大於 32 就是沒錯誤囉 發表人 - Justmade 於 2003/04/10 17:49:06 |
hagar
版主 發表:143 回覆:4056 積分:4445 註冊:2002-04-14 發送簡訊給我 |
|
lin11112
初階會員 發表:42 回覆:83 積分:25 註冊:2003-02-17 發送簡訊給我 |
|
RaynorPao
版主 發表:139 回覆:3622 積分:7025 註冊:2002-08-12 發送簡訊給我 |
引言: 我是用BCB 5.0 如果寫成如下 if ShellExecute(0, 'open', PChar('C:\xxx.exe'), nil, nil, SW_SHOW) <32 then ShowMessage('執行 C:\xxx.exe 發生錯誤: ' SysErrorMessage(GetLastError)); 在compiler時會有 Expression syntax的錯誤 lin11112 你好: (1)如果你是使用 C Builder 的話,可以寫成以下這樣子 >( >,不然會被 扣分的 > --
------
-- 若您已經得到滿意的答覆,請適時結案!! -- -- 欲知前世因,今生受者是;欲知來世果,今生做者是 -- -- 一切有為法,如夢幻泡影,如露亦如電,應作如是觀 -- |
本站聲明 |
1. 本論壇為無營利行為之開放平台,所有文章都是由網友自行張貼,如牽涉到法律糾紛一切與本站無關。 2. 假如網友發表之內容涉及侵權,而損及您的利益,請立即通知版主刪除。 3. 請勿批評中華民國元首及政府或批評各政黨,是藍是綠本站無權干涉,但這裡不是政治性論壇! |