File Open dialog does not display on Windows 7
-
Thursday, August 30, 2012 3:55 PM
I have developed an MFC apllication using VS 2008 on a Windows Pro XP x64 machine with .NET Framework 3.5.
I have installed the program on a Windows 7 machine and it works fine except that the file open/save dialogs will not display. They work fine on XP 32 and 64-bit machines.
Mike
All Replies
-
Thursday, August 30, 2012 4:03 PM
Hello Mike,
Can you provide some code snippets so we can take a look?
Thanks
Cameron Conacher
-
Thursday, August 30, 2012 4:32 PM
Here is the routine that is called from a display dialog to allow the user to open a file to save the text displayed in the dialog.
void CCDAOutDetDlg::OnBnClickedBtnWrite() { // TODO: Add your control notification handler code here OPENFILENAME ofn; // common dialog box structure char szFile[260]; // buffer for file name HWND hwnd = NULL; // owner window // Initialize OPENFILENAME ZeroMemory(&ofn, sizeof(ofn)); ofn.lStructSize = sizeof(ofn); ofn.hwndOwner = hwnd; ofn.lpstrFile = szFile; // Set lpstrFile[0] to '\0' so that GetOpenFileName does not // use the contents of szFile to initialize itself. ofn.lpstrFile[0] = '\0'; ofn.nMaxFile = sizeof(szFile); CString gname; if ( "Output to ProE" == m_strTitle) { gname = clgGear[m_iGearSel].gearid; gname = gname + "_proE"; strcpy(ofn.lpstrFile,gname); ofn.lpstrFilter = "(*.c2p)\0*.c2p\0"; //All Files (*.*)\0*.*\0 ofn.lpstrDefExt = "c2p"; } else { ofn.lpstrFilter = "(*.txt)\0*.txt\0"; //All Files (*.*)\0*.*\0 ofn.lpstrDefExt = "txt"; } ofn.nFilterIndex = 1; ofn.lpstrFileTitle = NULL; ofn.nMaxFileTitle = 0; ofn.lpstrInitialDir = clgClashHome; ofn.Flags = OFN_PATHMUSTEXIST | OFN_FILEMUSTEXIST; // Display the Open dialog box. CString strFileName; if (GetSaveFileName(&ofn)==TRUE) //IDOK strFileName = ofn.lpstrFile; else //IDCANCEL return; //CString strFileName; //CString strFilter = "(*.txt)|*.txt|All Files (*.*)|*.*||"; //CFileDialog dlg(FALSE,"txt","*.txt",OFN_HIDEREADONLY,strFilter); //dlg.m_ofn.lpstrInitialDir = clgClashHome; //if ( IDOK == dlg.DoModal() ) // strFileName = dlg.GetFileName(); //else // return; FILE *file_ptr; file_ptr = fopen(strFileName,"w"); if (NULL == file_ptr) { CString str; str.Format("Error writing file %s.",strFileName); CMsgDlg dlg("Warning", str, 0); dlg.DoModal(); return; } /* Create strings for title */ CString str; if (0 == m_iFlag) //No load & reduction option str = m_strText[0]; else { str = m_strText[m_iSel]; } str.Replace("\r\n","\n"); fputs(str, file_ptr); fclose(file_ptr); }Mike -
Thursday, August 30, 2012 4:59 PM
Here is the header file associated with the code I sent.
CDAOutDetDlg.h
#pragma once #include "mycolorbtn.h" #include "ReSizableDialog.h" #define MARGIN 2 class CCDAOutDetDlg : public CResizableDialog { DECLARE_DYNAMIC(CCDAOutDetDlg) public: int m_iGearSel; CString m_str; int m_iFormFeedCount; int m_iFormFeedIndex[100]; int m_iMaxPage; int m_iLineCount; int m_iLineCountPage; int m_iLineHeight; CFont m_font; CFont m_fontPrint; CFont* m_pOldFont; int m_iFlgModal; //0=modeless, 1=modal int m_iFlag; //0=default, 1=results change with RR&Load int m_iFlgCount; //0=not visible, 1=visible int m_iFlgPrint; //0=not visible, 1=visible int m_iFlgWrite; //0=not visible, 1=visible int m_iFlgPrintDlg; //0=no printer setting dialog, 1=pop up printer setting dialog int m_iRR; int m_iLoad; CBrush m_brush; int m_iCount; CString m_strTitle; CString m_strText[28]; void OnBeginPrinting(CDC * pDC, CPrintInfo * pInfo); void OnEndPrinting(CDC* pDC, CPrintInfo* pInfo); void OnPrint(CDC* pDC, CPrintInfo* pInfo); CCDAOutDetDlg(CWnd* pParent = NULL); // standard constructor virtual ~CCDAOutDetDlg(); // Dialog Data enum { IDD = IDD_CDA_OUTDET }; protected: virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support DECLARE_MESSAGE_MAP() public: CMyColorBtn m_btnPrint; CMyColorBtn m_btnWrite; CMyColorBtn m_btnCancel; virtual BOOL OnInitDialog(); afx_msg void OnBnClickedCancel(); afx_msg HBRUSH OnCtlColor(CDC* pDC, CWnd* pWnd, UINT nCtlColor); afx_msg void OnBnClickedBtnWrite(); afx_msg void OnBnClickedBtnPrint(); afx_msg void OnCbnSelchangeCombo(); int m_iSel; };Mike -
Thursday, August 30, 2012 5:11 PM
-
Thursday, August 30, 2012 5:54 PM
Hello Cameron,
I tried both setting this value to NULL and the c:\users\public\documents directory to no affect. These changes did not have an affect on the program when run on an XP machine, it worked fine.
Mike
-
Thursday, August 30, 2012 6:17 PM
Hello Mike,
Can you try one more thing.
Can you run the Application as Administrator?
Just trying to rule out UAC, if it is the issue.
Cameron Conacher
-
Thursday, August 30, 2012 6:47 PM
Cameron,
I have Admin rights, but I also right-clicked and ran as Administer - no change.
Here are the values for ofn in my code from the debugger on the XP machine just prior to calling GetSaveFileName.
ofn {lStructSize=88 hwndOwner=0x00000000 hInstance=0x00000000 ...}tagOFNA
lStructSize 88 unsigned long
hwndOwner 0x00000000 {unused=??? } HWND__ *
hInstance 0x00000000 {unused=??? } HINSTANCE__ *
lpstrFilter 0x00ab8698 "(*.txt)" const char *
lpstrCustomFilter 0x00000000 <Bad Ptr> char *
nMaxCustFilter 0 unsigned long
nFilterIndex 1 unsigned long
lpstrFile 0x0cf1e5ac "" char *
nMaxFile 260 unsigned long
lpstrFileTitle 0x00000000 <Bad Ptr> char *
nMaxFileTitle 0 unsigned long
lpstrInitialDir 0x1108bc20 "C:\Data\CLASH" const char *
lpstrTitle 0x00000000 <Bad Ptr> const char *
Flags 6144 unsigned long
nFileOffset 0 unsigned short
nFileExtension 0 unsigned short
lpstrDefExt 0x00ab8694 "txt" const char *
lCustData 0 long
lpfnHook 0x00000000 unsigned int (HWND__ *, unsigned int, unsigned int, long)*
lpTemplateName 0x00000000 <Bad Ptr> const char *
pvReserved 0x00000000 void *
dwReserved 0 unsigned long
FlagsEx 0 unsigned longMike
-
Friday, August 31, 2012 12:19 AM
Mike,
I cut and pasted the code from your list above
// TODO: Add your control notification handler code here OPENFILENAME ofn; // common dialog box structure WCHAR szFile[260]; // buffer for file name HWND hwnd = NULL; // owner window // Initialize OPENFILENAME ZeroMemory(&ofn, sizeof(ofn)); ofn.lStructSize = sizeof(ofn); ofn.hwndOwner = hwnd; ofn.lpstrFile = szFile; // Set lpstrFile[0] to '\0' so that GetOpenFileName does not // use the contents of szFile to initialize itself. ofn.lpstrFile[0] = '\0'; ofn.nMaxFile = sizeof(szFile); CString gname; { ofn.lpstrFilter = _T("(*.txt)\0*.txt\0"); //All Files (*.*)\0*.*\0 ofn.lpstrDefExt = _T("txt"); } ofn.nFilterIndex = 1; ofn.lpstrFileTitle = NULL; ofn.nMaxFileTitle = 0; ofn.Flags = OFN_PATHMUSTEXIST | OFN_FILEMUSTEXIST; // Display the Open dialog box. CString strFileName; if (GetSaveFileName(&ofn)==TRUE) //IDOK strFileName = ofn.lpstrFile;And it ran fine on my windows 7 Home Premium box.
Visual Studio 2008.
I know that does not help you a whole lot, but it does work on my machine.
Cameron Conacher
-
Friday, August 31, 2012 1:03 PM
Hi Cameron,
I replaced my code with a copy of yours. One thing you had changed was "WCHR szfile[260];" which I had to revert to my original code "char szfile[260];" because I got the compile error with yours
1>..\..\C++_src\CDAOutDetDlg.cpp(187) : error C2440: '=' : cannot convert from 'WCHAR [260]' to 'LPSTR'
1> Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
Anyway, I still had the same problem when running the executable on my Windows 7 Pro sp1 machine, the file open/save dialog will not display.
We have had other problems writing files with other programs because of UAC which were resolved by changing user directory rights. However, I would think that this problem is not due to UAC, because I am not even trying to write a file at this point, I'm only trying to display the dialog.
Mike
-
Friday, August 31, 2012 1:42 PM
Hello Mike,
Yes, my application environment was set up as Unicode, so I had to change the char to WCHAR, and add the _T("") wrapping.
I know this is a more "invasive" change, but I have used the code snippet below successfully.
If this does not work for you either, I would really look into the UAC.
/** Prompt the User to select a Path for the DataBase Backups, using a Folder Picker */ void CAdvancedCustomization::OnBnClickedDefaultBackupPath() { TCHAR szDestinationFolder[_MAX_PATH]; CString szBuffer; BROWSEINFO bi; ITEMIDLIST* pItemIdList; TCHAR szFolder[_MAX_PATH]; memset(&bi,0,sizeof(bi)); bi.hwndOwner=m_hWnd; bi.pszDisplayName=szFolder; bi.lpszTitle=_T("Please select a folder where you wish to store your DataBase Backup information."); if ((pItemIdList=SHBrowseForFolder(&bi))!=NULL) { SHGetPathFromIDList(pItemIdList, szDestinationFolder); szBuffer.Format(_T("%s\\ClinicDB.bak"), szDestinationFolder); m_DataBaseDefaultBackupPath.SetWindowText(szBuffer); } else m_DataBaseDefaultBackupPath.SetWindowText(_T("")); }
Cameron Conacher
-
Friday, August 31, 2012 2:27 PM
Cameron,
Using your code I am able to display the dialog and select a folder.
Mike
-
Friday, August 31, 2012 2:52 PM
Sorry I cannot explain why your original code does not work.
But, haappy that you have a solution.
Cameron Conacher
-
Friday, August 31, 2012 3:12 PM
Cameron,
Your code worked in that it allowed me to display a dialog in Windows 7. The dialog I was able to display would allow me to select a directory path, but it does not have near the same functionality as the Open/Save dialog.
This should demonstrate that UAC is not the problem - I'm able to display a dialog that looks at the directory structure. The problem must have something to do with the Open/Save dialog itself or that the coding for calling it for use in Windows 7 is different than in Windows XP.
I have tried setting the Compatability of the executable to Windows XP sp2, but it had no affect.
Mike
-
Friday, August 31, 2012 3:29 PM
Hello again Mike,
Here is another snippet I use when I am selecting a file:
/** Open a File Picker Dialog, and if the Dialog is CANCELLed, then we have nothing more to do. */ szDocumentFileName =_T("C:\\*.*"); TCHAR strFileFilters[]= _T("All Files (*.*)|*.*||"); CFileDialog fdNewImage(TRUE, szDocumentFileName+_T("All Files (*.*)"), _T("*.*"), OFN_FILEMUSTEXIST, strFileFilters); if (fdNewImage.DoModal()!=IDOK) { return; } szDocumentFileAndPathName = fdNewImage.GetPathName(); szDocumentFileName = fdNewImage.GetFileName();This works for me when I want to select a file name.
This is just a File Picker Dialog.
I did a little looking and found the following link: http://msdn.microsoft.com/en-us/library/windows/desktop/ms646928(v=vs.85).aspx
The link indicates that the Open and SaveAs Common Dialogs have been superseded.
And, again, none of this explains why your code works on my machine, and not on yours.
Does GetLastError return anything meaningful, when your code runs?
Cameron Conacher
-
Friday, August 31, 2012 3:59 PM
Mike I found some additional information
Check out this link.
http://stackoverflow.com/questions/4982680/getopenfilename-fails-in-64-bit-but-works-in-32bit
I have the very same problem and a partial solution : + the simple following simple example (proposed abobe) was not working in x64 mode. + I changed the complie option "struct Member Alignment" from 1byte /Zp1 to default which solved this problem (by introducing others !!!)
char Filestring[MAX_PATH] = "\0"; OPENFILENAME opf={0}; opf.lStructSize = sizeof(OPENFILENAME); opf.lpstrFile = Filestring; opf.nMaxFile = MAX_PATH; GetOpenFileName(&opf);
Cameron Conacher
-
Friday, August 31, 2012 7:02 PM
Cameron,
I inserted and ran the following code:
// Open a File Picker Dialog char strFileFilters[]= "All Files (*.*)|*.*||"; CFileDialog fdNewImage(TRUE, "C:\\*.* All Files (*.*)", "*.*", OFN_FILEMUSTEXIST, strFileFilters); MessageBox("Calling fdNewImage", MB_OK); if (fdNewImage.DoModal()!=IDOK) { DWORD dw = GetLastError(); CString str; str.Format("GetLastError = %d", dw); MessageBox(str, MB_OK); return; } MessageBox("Called fdNewImage successfully", MB_OK);It displayed the first message box, did not display the dialog, failed in the if check and displayed the 2nd message box with GetLastError = 0.
Mike
-
Friday, August 31, 2012 8:26 PM
Unbelievable!! :-)
O.K. try using CommDlgExtendedError to get error information.
http://msdn.microsoft.com/en-us/library/3xb6dhth(v=vs.100)
Cameron Conacher
-
Friday, August 31, 2012 8:29 PM
I'll try Tuesday. Have a nice holiday.
Mike
-
Saturday, September 01, 2012 7:22 PM
Cameron,
CommDlgExtendedError returns a value of 2 for all three approaches to opening a file save dialog on Windows 7. It returns 0 on XP.
The description for CommDlgExtendedError says that 2 means a failure to initialize, possibility due to insufficient memory. Surely that is not the problem here. I ran the app immediately after rebooting. The Windows 7 machine resource monitor shows Physical Memory at 1641 MB in use and 2308 MB Available when the app is running.
Adding CommDlgExtendedError to my search items turns up quite a few questions about this problem with the solution being to make sure the first character of lpstrFile is set to null. My code already has lpstrFile set to null.
char Filestring[MAX_PATH] = "\0"; OPENFILENAME opf={0}; opf.lStructSize = sizeof(OPENFILENAME); opf.lpstrFile = Filestring; opf.nMaxFile = MAX_PATH; GetOpenFileName(&opf); CString str1; DWORD dw = CommDlgExtendedError(); str1.Format("CommDlgExtendedError = %d", dw); MessageBox(str1, MB_OK);Mike
- Edited by Mike Kipling Saturday, September 01, 2012 9:09 PM
-
Monday, September 03, 2012 2:36 AM
Cameron,
I have rebuilt my solution on a Windows 7 Pro sp1 machine, but it still has the same problem. When I call GetOpenFileName with the following routine, CommDlgExtendedError returns a 2.
void OnFileOpenTest() { // TODO: Add your command handler code here OPENFILENAME ofn; // common dialog box structure char szFile[260]; // buffer for file name HWND hwnd = NULL; // owner window // Initialize OPENFILENAME ZeroMemory(&ofn, sizeof(ofn)); ofn.lStructSize = sizeof(ofn); ofn.lpstrFile = szFile; ofn.hwndOwner = hwnd; ofn.nMaxFile = MAX_PATH; // Set lpstrFile[0] to '\0' so that GetOpenFileName does not // use the contents of szFile to initialize itself. ofn.lpstrFile[0] = '\0'; ofn.nMaxFile = sizeof(szFile); // Display the Open dialog box. CString strFileName; if (GetOpenFileName(&ofn)==TRUE) //IDOK strFileName = ofn.lpstrFile; else //IDCANCEL { DWORD dw = CommDlgExtendedError(); return; } }I did find this article for using the newer Common Item Dialogs, but for ATL/WTL.
http://www.codeproject.com/Articles/16678/Vista-Goodies-in-C-Using-the-New-Vista-File-Dialog
I do not understand why the older dialogs work on your machine and not mine. Can you supply sample code for using the newer dialogs in MFC for me to try?
Mike
-
Monday, September 03, 2012 5:14 AM
Cameron,
I tried using the example code from:
http://msdn.microsoft.com/en-us/library/3xb6dhth(v=vs.100).aspx
void CMyClass::OnFileOpen() { // szFilters is a text string that includes two file name filters: // "*.my" for "MyType Files" and "*.*' for "All Files." TCHAR szFilters[]= _T("MyType Files (*.my)|*.my|All Files (*.*)|*.*||"); // Create an Open dialog; the default file name extension is ".my". CFileDialog fileDlg(TRUE, _T("my"), _T("*.my"), OFN_FILEMUSTEXIST | OFN_HIDEREADONLY, szFilters); // Display the file dialog. When user clicks OK, fileDlg.DoModal() // returns IDOK. if(fileDlg.DoModal() == IDOK) { CString pathName = fileDlg.GetPathName(); // Implement opening and reading file in here. //Change the window's title to the opened file's title. CString fileName = fileDlg.GetFileTitle(); SetWindowText(fileName); } }but when the line "if(fileDlg.DoModal() == IDOK)" is executed, the program hangs and issues a beep every time the mouse is clicked.
This example code is for VS 2010. The page can list code for each version of VS except 2008.
Mike
-
Monday, September 03, 2012 4:18 PM
Cameron,
The program hangs in dlgfile.cpp on the HRESULT line below in the debugger.
if (m_bVistaStyle == TRUE) { ApplyOFNToShellDialog(); HRESULT hr = (static_cast<IFileDialog*>(m_pIFileDialog))->Show(m_ofn.hwndOwner); // Hangs here nResult = (hr == S_OK) ? IDOK : IDCANCEL; } else if (m_bOpenFileDialog) nResult = ::AfxCtxGetOpenFileName(&m_ofn); else nResult = ::AfxCtxGetSaveFileName(&m_ofn);Mike -
Monday, September 03, 2012 7:19 PM
Hello Mike,
Long weekend here in Canada.
The "beeping" action above got me wondering what you have in the MyClass?
Does MyClass derive from a Dialog?
I sounds (no pun intendedd) as if the File Dialog has been launched, and when you click outside the dialog it beeps.
Cameron Conacher
-
Tuesday, September 04, 2012 12:18 PM
Cameron,
I'm sorry, but I do not understand your question.
Below is the actual code I am using based on the example code from msdn. The beep came from my home machine. My Windows 7 machine at work does not issue a beep, it simply pauses for 2 seconds, then the main dialog will accept input again.
When I run in debug on my XP machine, the program steps to the second if check in dlgfile.cpp as it should and displays the open file dialog properly. On the Windows 7 machine it uses the first if check.
void CWindowsCLASHView::OnFileOpenClash() { // TODO: Add your command handler code here //OnFileOpenTest(); // szFilters is a text string that includes two file name filters: // "*.my" for "MyType Files" and "*.*' for "All Files." char szFilters[]= "MyType Files (*.my)|*.my|All Files (*.*)|*.*||"; // Create an Open dialog; the default file name extension is ".my". CFileDialog fileDlg(TRUE, "my", "*.my", OFN_FILEMUSTEXIST | OFN_HIDEREADONLY, szFilters); // Display the file dialog. When user clicks OK, fileDlg.DoModal() // returns IDOK. if(fileDlg.DoModal() == IDOK) { CString pathName = fileDlg.GetPathName(); // Implement opening and reading file in here. //Change the window's title to the opened file's title. CString fileName = fileDlg.GetFileTitle(); SetWindowText(fileName); } }
Image from an XP machine.
-
Tuesday, September 04, 2012 2:27 PM
Mike,
Can you zip up your project and email it to me?
I will try to compile/run on my windows 7 machine for you.
Let me know when/if you send it, so I can delete my email from this posting.
Cameron Conacher
- Edited by Cameron_C Wednesday, September 12, 2012 7:04 PM Corrected a typo.
-
Tuesday, September 04, 2012 2:50 PM
Mke,
Can you try changing the szFilters definition to TCHAR?
As well as _T("my"), _T("*.my")
explicit CFileDialog( BOOL bOpenFileDialog, LPCTSTR lpszDefExt = NULL, LPCTSTR lpszFileName = NULL, DWORD dwFlags = OFN_HIDEREADONLY | OFN_OVERWRITEPROMPT, LPCTSTR lpszFilter = NULL, CWnd* pParentWnd = NULL, DWORD dwSize = 0 );
Cameron Conacher
-
Tuesday, September 04, 2012 4:15 PM
Cameron,
I changed the two lines to :
TCHAR szFilters[]= _T("MyType Files (*.my)|*.my|All Files (*.*)|*.*||"); CFileDialog fileDlg(TRUE, _T("my"), _T("*.my"), OFN_FILEMUSTEXIST | OFN_HIDEREADONLY, szFilters);but it had made no difference.
Here is part of the definition for CFileDialog from afxdlgs.h
class CFileDialog : public CCommonDialog { DECLARE_DYNAMIC(CFileDialog) public: // Attributes __declspec(property(get=GetOFN)) OPENFILENAME m_ofn; const OPENFILENAME& GetOFN() const; OPENFILENAME& GetOFN(); LPOPENFILENAME m_pOFN; // Constructors explicit CFileDialog(BOOL bOpenFileDialog, // TRUE for FileOpen, FALSE for FileSaveAs LPCTSTR lpszDefExt = NULL, LPCTSTR lpszFileName = NULL, DWORD dwFlags = OFN_HIDEREADONLY | OFN_OVERWRITEPROMPT, LPCTSTR lpszFilter = NULL, CWnd* pParentWnd = NULL, DWORD dwSize = 0, BOOL bVistaStyle = TRUE); virtual ~CFileDialog();Mike -
Tuesday, September 04, 2012 4:24 PM
Mike,
I still cannot explain this, but can you try chaning your Constructor to :
CFileDialog fileDlg(TRUE, _T("my"), _T("*.my"),
OFN_FILEMUSTEXIST | OFN_HIDEREADONLY, szFilters, NULL, 0, FALSE);
Cameron Conacher
-
Tuesday, September 04, 2012 7:08 PM
Cameron,
I made the change, and the program works fine on Windows XP, but now on the Windows 7 machine I get the beep when clicking the mouse. The program will not proceed past this point.
Mike
-
Tuesday, September 04, 2012 7:14 PM
Mike,
Can you zip it up and send me the entire project?
Cameron Conacher
-
Tuesday, September 04, 2012 8:46 PM
Cameron,
How would I contact you? Can you contact me offline?
Mike
-
Tuesday, September 04, 2012 11:15 PM
Cameron,
My solution contains over a thousand source files, 3 projects (to create two DLLs (C and Fortran)and an executable) and links to numerous libraries. I could send you just the CPP & .h source code (322 files) if you want it.
I did download an MSDN sample project, and modified it to test two different methods (CFileDialog and GetOpenFileName) of opening the dialog. Both worked without a problem building and executing on my Windows 7 machine. I'll test it tomorrow on my XP machine, but I'm sure it will work there also.
Mike
-
Wednesday, September 05, 2012 2:16 AM
Hello Mike,
If the MSDN project works fine for you then there is not much more I can say.
Somehow somewhere, something is going wrong in your app.
The code work for you in the MSDN samples, right?
But when you use the same code in your project i fails?
Hmmmmmmm.
You can contact me offlist if you want to yack about it.
Cameron Conacher
-
Wednesday, September 05, 2012 1:08 PM
Cameron,
How do I send you a zip file?
The MSDN app works on XP also with the same code that is used in my app. I am going to try to make a simple version for testing of my app with most of the calls and the other two dll projects eliminated. This may allow me to track down the problem.
If the simple version still does not work, I will send it to you.
Mike
-
Wednesday, September 05, 2012 2:44 PM
You can zip it and email it to me.
Send it to Cameron_Conacher at Hotmail dot Com.
Cameron Conacher
-
Saturday, September 08, 2012 7:47 PM
Cameron,
I have sent two zip files to you via two emails for my solution with all of the Fortran and C routines removed, and for the MSDN solution which I am using to compare with in debug.
I am seeing some differences when comparing values, but have not determined what is causing my program to not display the Open File dialog.
Mike
-
Wednesday, September 19, 2012 5:41 PM
Cameron,
I contracted with Microsoft Support to help find a solution, and within 2 days it was found.
I had set the project property for "Linker/System/Stack Reserve Size" = 200 mb. Reducing this value to 50 mb solved the problem in Win 7, and the program was still able to run properly.
Using the default value of 1 mb allowed the open file dialog to display properly, but I get a stack overflow error when I try to do any calculations with the program.
Thanks for the help.
Mike
- Marked As Answer by Mike Kipling Wednesday, September 19, 2012 5:42 PM

