Click here to Skip to main content
15,922,574 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Behaviour of CreateThread compared to AfxBeginThread Pin
Naveen1-Jun-09 0:41
Naveen1-Jun-09 0:41 
GeneralRe: Behaviour of CreateThread compared to AfxBeginThread Pin
sunny_vc1-Jun-09 0:44
sunny_vc1-Jun-09 0:44 
GeneralRe: Behaviour of CreateThread compared to AfxBeginThread Pin
Saurabh.Garg1-Jun-09 0:54
Saurabh.Garg1-Jun-09 0:54 
GeneralRe: Behaviour of CreateThread compared to AfxBeginThread Pin
Naveen1-Jun-09 1:09
Naveen1-Jun-09 1:09 
GeneralRe: Behaviour of CreateThread compared to AfxBeginThread Pin
Rajesh R Subramanian2-Nov-10 7:04
professionalRajesh R Subramanian2-Nov-10 7:04 
Questionwho recommand book about ood? Pin
Archy_Yu31-May-09 23:21
Archy_Yu31-May-09 23:21 
Questionprogramming GSM network with c language Pin
agetina31-May-09 22:05
agetina31-May-09 22:05 
AnswerRe: programming GSM network with c language Pin
CPallini31-May-09 22:20
mveCPallini31-May-09 22:20 
AnswerRe: programming GSM network with c language Pin
emrahustun31-May-09 22:28
emrahustun31-May-09 22:28 
AnswerRe: programming GSM network with c language Pin
randomrockers31-May-09 22:33
randomrockers31-May-09 22:33 
QuestionMouse Event Pin
Davitor31-May-09 21:48
Davitor31-May-09 21:48 
AnswerRe: Mouse Event Pin
«_Superman_»31-May-09 21:50
professional«_Superman_»31-May-09 21:50 
GeneralRe: Mouse Event Pin
Davitor31-May-09 23:08
Davitor31-May-09 23:08 
GeneralRe: Mouse Event Pin
David Crow1-Jun-09 3:17
David Crow1-Jun-09 3:17 
AnswerRe: Mouse Event Pin
CPallini31-May-09 21:51
mveCPallini31-May-09 21:51 
GeneralRe: Mouse Event Pin
Davitor1-Jun-09 2:53
Davitor1-Jun-09 2:53 
GeneralRe: Mouse Event Pin
CPallini1-Jun-09 3:02
mveCPallini1-Jun-09 3:02 
GeneralRe: Mouse Event Pin
Davitor1-Jun-09 19:26
Davitor1-Jun-09 19:26 
Questionreading a .pst file Pin
Anil Kumar.Arvapalli31-May-09 21:21
Anil Kumar.Arvapalli31-May-09 21:21 
AnswerRe: reading a .pst file Pin
randomrockers31-May-09 22:41
randomrockers31-May-09 22:41 
AnswerRe: reading a .pst file Pin
Stuart Dootson31-May-09 23:11
professionalStuart Dootson31-May-09 23:11 
Questionopening webcam with MFC Pin
randomrockers31-May-09 21:19
randomrockers31-May-09 21:19 
AnswerRe: opening webcam with MFC Pin
khan++31-May-09 22:33
khan++31-May-09 22:33 
Questionusing ShellExecute to close... Pin
randomrockers31-May-09 21:17
randomrockers31-May-09 21:17 
Hi, i am using ShellExecute to open an image. The image is opened using Windows Picture and Fax Viewer. Now, I have a button, in my dialog(the UI). I want to close the Windows Picture and Fax Viewer, got any idea? here's my code... please help. its kinda urgent... been stuck on this for 3 days... googled it, but nopthing relevant came out.

void CDesignDlg::OnImage()
{
// TODO: Add your control notification handler code here
CFileDialog m_ldFile(TRUE);

{
if ( ! onStart )
{
m_button.SetWindowText("Start Image");
}
else
{
m_button.SetWindowText("Stop Image");
}

onStart ^= 1; // make onStart 0, or 1 respectively

}


if (onStart==0){

if (m_ldFile.DoModal() ==IDOK)
{


CString abc= m_ldFile.GetPathName();
SHELLEXECUTEINFO tiff;
tiff.cbSize = sizeof(SHELLEXECUTEINFO);
tiff.fMask = NULL;
tiff.hwnd = NULL;
tiff.lpVerb = "open";
tiff.lpFile = abc;
tiff.lpParameters= NULL;
tiff.nShow = SW_SHOWNORMAL;
tiff.hInstApp = NULL;
tiff.lpIDList = NULL;
tiff.lpClass = NULL;
tiff.hkeyClass = NULL;
tiff.dwHotKey = NULL;
tiff.hIcon = NULL;
tiff.hProcess = NULL;
tiff.lpDirectory = NULL;
int ReturnCode = ::ShellExecuteEx(&tiff);

UpdateData(TRUE);

}}
else
{
//what should be put here???
}


}
AnswerRe: using ShellExecute to close... Pin
tolw31-May-09 21:35
tolw31-May-09 21:35 

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.