halfinfinite
asked on
FileOpen/folder browsing dialog with WinCE.
I am building a configuration app for PocketPC 2003 using WTL for WinCE. One phase of my configuration is to associate/dissociate other applications with my own. I am currently using the CFileOpen common dialog box, but in WinCE, this only allows me to browse certain folders, and not anywhere that .exe files are located. This pretty much renders the CFileOpen dialog useless to me.
I have also tried to use the system GetOpenFileName() system call using the OPENFILENAME structure filled in, but this also is not working.
I would imagine that this is a common problem, does anyone know a solution? How does one accomplish a full file-browsing dialog in WinCe?
I have also tried to use the system GetOpenFileName() system call using the OPENFILENAME structure filled in, but this also is not working.
I would imagine that this is a common problem, does anyone know a solution? How does one accomplish a full file-browsing dialog in WinCe?
ASKER
I tried the following:
CFileDialog dlg(TRUE, _T("exe"), NULL,
OFN_FILEMUSTEXIST | OFN_HIDEREADONLY | OFN_PATHMUSTEXIST,
_T("Applications\0*.exe\0A ll Files\0*.*\0"), this->m_hWnd);
if (dlg.DoModal()==IDOK)
{
m_szAppName = (CString) dlg.m_szFileTitle;
DoDataExchange(FALSE);
};
I tried to use the OpenFileName common dialog, but I cannot get it to work...OpenFileName is undefined, nor can I find it in commdlg.h.
CFileDialog dlg(TRUE, _T("exe"), NULL,
OFN_FILEMUSTEXIST | OFN_HIDEREADONLY | OFN_PATHMUSTEXIST,
_T("Applications\0*.exe\0A
if (dlg.DoModal()==IDOK)
{
m_szAppName = (CString) dlg.m_szFileTitle;
DoDataExchange(FALSE);
};
I tried to use the OpenFileName common dialog, but I cannot get it to work...OpenFileName is undefined, nor can I find it in commdlg.h.
evc or c++ .net
ASKER
I am using evc++ 4.0
I will also check out the codeguru link....thanks.
I will also check out the codeguru link....thanks.
What exactly is the symptom? What is your Windows Explorer setting (menu View/Options)?
ASKER
Hello-
The symptom is that the CFileDialog only permits browsing from the "My Documents" level on my WinCE device. I need to be able to browse from the root, and cannot see any way of setting this dialog to do so.
The symptom is that the CFileDialog only permits browsing from the "My Documents" level on my WinCE device. I need to be able to browse from the root, and cannot see any way of setting this dialog to do so.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
what should he get from that answer?
Oops, I guess that would be the same as your answer.
I saw your code and i even tried it thats what i was asking sorry,,,
ASKER
Hi, the tillanosoft .dll is the only solution I've found that works. I'm not sure if I can get the budget to license it though! ;) But thanks for all your help!
Did you try the common dialog?