|
I have tried all that! It makes no apparent difference what I initialise and what I don't. It also happens for both CFileDialog and GetOpenFileName.
RA
|
|
|
|
|
your problem is GetOpenFileName or you get a error when use this function
whitesky
|
|
|
|
|
The application crashes. I get a message box: "Unhandled exception in BareSDKTest.exe (SHELL32.DLL): 0xC0000005: Access Violation". When not debugging, the app just ends.
Interestingly, it seems to happen as the little box with the information about the file under the mouse pointer pops up.
It only happens when I access the desktop, only on the third or fourth occasion and only when the mouse goes to select a file. It also happens if I use the tab/cursor keys.
It doesn't happen with other directories. The file type under the mouse makes no difference either.
RA
|
|
|
|
|
|
Thanks! That's really useful. I also have Acrobat 7.0 and have experienced exactly the symptoms described.
At least it's not me!
RA
|
|
|
|
|
im not sure your problem is this but can you run this code ,please and send me that it work or you get previous error
<br />
OPENFILENAME m_ofn;<br />
static char lpFile[260];<br />
LPCSTR szFilter="";<br />
memset(&m_ofn, 0, sizeof(m_ofn));<br />
m_ofn.lStructSize = sizeof(OPENFILENAME);<br />
m_ofn.hwndOwner = m_hWnd;<br />
m_ofn.hInstance = AfxGetApp()->m_hInstance;<br />
m_ofn.lpstrFilter = szFilter;<br />
m_ofn.lpstrCustomFilter = NULL;<br />
m_ofn.nMaxCustFilter = 0;<br />
m_ofn.nFilterIndex = 0;<br />
m_ofn.lpstrFile = lpFile;<br />
<br />
m_ofn.nMaxFile = sizeof(lpFile);<br />
m_ofn.lpstrFileTitle = 0;<br />
m_ofn.nMaxFileTitle = 0;<br />
m_ofn.lpstrInitialDir = NULL;<br />
<br />
m_ofn.lpstrTitle = "Open a File";<br />
m_ofn.nFileOffset = 0;<br />
m_ofn.nFileExtension = 0;<br />
m_ofn.lpstrDefExt = NULL;<br />
m_ofn.lCustData = 0;<br />
m_ofn.lpfnHook = NULL;<br />
m_ofn.lpTemplateName = NULL;<br />
<br />
m_ofn.Flags = OFN_EXPLORER|OFN_HIDEREADONLY;<br />
GetOpenFileName(&m_ofn);<br />
whitesky
|
|
|
|
|
Thank you for your help. I had to slightly alter the code you sent:
char szFilter[256];<br />
OPENFILENAME m_ofn;<br />
<br />
char file[256];<br />
char* lpFile;<br />
.<br />
.<br />
.<br />
case ID_FILE_WHITESKYOPEN:<br />
lpFile = file;<br />
*lpFile = '\0';<br />
ZeroMemory(&m_ofn, sizeof(OPENFILENAME));<br />
<br />
m_ofn.lStructSize = sizeof(ofn);<br />
m_ofn.hInstance = hInst;<br />
m_ofn.lpstrFilter = szFilter;<br />
m_ofn.lpstrCustomFilter = NULL;<br />
m_ofn.nMaxCustFilter = 0;<br />
m_ofn.nFilterIndex = 0;<br />
m_ofn.lpstrFile = lpFile;<br />
<br />
m_ofn.nMaxFile = sizeof(lpFile);<br />
m_ofn.lpstrFileTitle = 0;<br />
m_ofn.nMaxFileTitle = 0;<br />
m_ofn.lpstrInitialDir = NULL;<br />
<br />
m_ofn.lpstrTitle = "Open a File";<br />
m_ofn.nFileOffset = 0;<br />
m_ofn.nFileExtension = 0;<br />
m_ofn.lpstrDefExt = NULL;<br />
m_ofn.lCustData = 0;<br />
m_ofn.lpfnHook = NULL;<br />
m_ofn.lpTemplateName = NULL;<br />
<br />
m_ofn.Flags = OFN_EXPLORER|OFN_HIDEREADONLY;<br />
<br />
GetOpenFileName(&m_ofn);<br />
break;<br />
But I am afraid it still does the same thing. It seems from the other replies I have received to my posting that this is not unique to me and somehow seems to relate to Adobe Acrobat 7.0.
I have not yet tried removing Acrobat 7.0 from my computer to prove the point.
Thank you again for your interest and help.
RA
|
|
|
|
|
Another post here suggested this company's software as a replacement for reading PDF files...
http://www.foxitsoftware.com
I've seen better runs in my shorts! - Patches O'Houlihan
|
|
|
|
|
|
http://x02.xanga.com/8aba2b046373560365677/m40459493.jpg[^]
Just like that. That is writen by C++. And i want to display the web image when i click the name in the list.
Is there any source code for displaying a web image into window application?????
web image is like that "http://x02.abc.com/peter.jpg"
-- modified at 4:02 Thursday 15th June, 2006
|
|
|
|
|
In your dialog you can put a Microsoft Web Browser ActiveX control, then use the Navigate2 member function to display the image. You can even display Web sites, not only images.
Alternatively, you can try to download the image using CHttpConnection MFC class, and then display it in a picture control.
|
|
|
|
|
Is there any example?? I am only a beginner of C++.
|
|
|
|
|
mimimimilaw wrote: Is there any source code for displaying a web image into window application?????
You may use the IHTMLDocument or IHTMLDocument2 Interface for this.
Knock out 't' from can't,
You can if you think you can
|
|
|
|
|
It seem too difficult to me....Is there easier way?
|
|
|
|
|
I guess you want that read links in one page and if this link is image then you download it,right?
whitesky
|
|
|
|
|
|
|
Hi,
I need to provide the user the ability to view and modify arrays that can have any dimensions. Which control or interface would you suggest to use for this to be nice ?
Thanks !
|
|
|
|
|
Tnarol wrote: Which control or interface would you suggest to use for this to be nice
CListCtrl
nave
|
|
|
|
|
hey all,
I am new to this area.
Iam trying to create a combobox with vertical scroll enabled.
I want to have some 9 items listed in the combobox. How do I list the items?
In the property page of that combobox,
enabled the "droplist" ,vertical scroll.
How do the items get displayed on the combobox after build of the program?
Any guide/help?
|
|
|
|
|
If you are using VS 2003, open dialog editor, select your combo-box, go to the Properties panel, and enter your items in the Data field. Separate items with semicolons.
|
|
|
|
|
You need to add the items to the combo box using
m_combo.AddString();
If you are not able to see the contents of the combo box ,select the combo box in resource editor.
Click on the arrow
Drag the combo box down with a click on the lower border.
That's it . You will see the contents when you click on the combo box
Somethings seem HARD to do, until we know how to do them.
_AnShUmAn_
|
|
|
|
|
I want to include some files in my project.but i dont want to place those files in my project folder.how can i include a file without place that in current project folder.
E-Ramu
|
|
|
|
|
Check in the project settings, there is an option in which you can specify additional include directories (it is in the C/C++ tab)
Cédric Moonen
Software developer
Charting control
|
|
|
|
|
While including the file give the entire path.
Appu..
"If you judge people, you have no time to love them."
|
|
|
|