q: 如何開啟乙個應用程式?
shellexecute(this->m_hwnd,"open","calc.exe","","", sw_show );
或shellexecute(this->m_hwnd,"open","notepad.exe",
"c:/mylog.log","",sw_show );
q: 如何開啟乙個同系統程式相關連的文件?
shellexecute(this->m_hwnd,"open",
"c:/abc.txt","","",sw_show );
q: 如何開啟乙個網頁?
q: 如何啟用相關程式,傳送email?
shellexecute(this->m_hwnd,"open",
q: 如何用系統印表機列印文件?
shellexecute(this->m_hwnd,"print",
"c:/abc.txt","","", sw_hide);
q: 如何用系統查詢功能來查詢指定檔案?
shellexecute(m_hwnd,"find","d:/nish",
null,null,sw_show);
q: 如何啟動乙個程式,直到它執行結束?
shellexecuteinfo shexecinfo = ;
shexecinfo.cbsize = sizeof(shellexecuteinfo);
shexecinfo.fmask = see_mask_nocloseprocess;
shexecinfo.hwnd = null;
shexecinfo.lpverb = null;
shexecinfo.lpfile = "c:/myprogram.exe";
shexecinfo.lpparameters = "";
shexecinfo.lpdirectory = null;
shexecinfo.nshow = sw_show;
shellexecuteex(&shexecinfo);
waitforsingleobject(shexecinfo.hprocess,infinite);
或:process_information processinfo;
startupinfo startupinfo; //入口引數
zeromemory(&startupinfo, sizeof(startupinfo));
startupinfo.cb = sizeof startupinfo ; //分配大小
if(createprocess("c:/winnt/notepad.exe", null,
null,null,false,0,null,
null,&startupinfo,&processinfo))
else
q: 如何顯示檔案或資料夾的屬性?
shellexecuteinfo shexecinfo =;
shexecinfo.cbsize = sizeof(shellexecuteinfo);
shexecinfo.fmask = see_mask_invokeidlist ;
shexecinfo.hwnd = null;
shexecinfo.lpverb = "properties";
shexecinfo.lpfile = "c:/"; //也可以是檔案
shexecinfo.lpparameters = "";
shexecinfo.lpdirectory = null;
shexecinfo.nshow = sw_show;
shellexecuteex(&shexecinfo);
深入淺出sizeof
int佔 位元組,short佔 位元組 1.0 回答下列問題 答案在文章末尾 1.sizeof char 2.sizeof a 3.sizeof a 4.strlen a 如果你答對了全部四道題,那麼你可以不用細看下面關於sizeof的論述。如果你答錯了部分題目,那麼就跟著我來一起 關於sizeof...
深入淺出ShellExecute
ipconfig c log.txt應如何處理?二樓的朋友,開啟拔號網路這樣 shellexecute null,open c windows rundll32.exe shell32.dll,control rundll c windows system telephon.cpl null,sw ...
深入淺出ShellExecute
深入淺出shellexecute譯者 徐景周 原作 nishant s q 如何開啟乙個應用程式?shellexecute this m hwnd,open calc.exe sw show 或shellexecute this m hwnd,open notepad.exe c mylog.log...