- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Steve,
I read not long ago you have a post about upgrading your example code from win32 to x64. I searched your name and after some pages still can't find it. Could you point me where it is.
Thank you very much.
Cheers,
Cean
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
What problem are you having? The example of GetOpenFileName in the 2019 Samples Bundle works for x64.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I can't remember what's the error under X64 a while ago. I just stick to Win32.
But now under Win32, every time I want to open a file, there maybe an Exception thrown: wkernelbase.pdb not loaded.
If I hit the green right arrow, the Open window can pops up, but some icons shown in black and after picking a file, my program is not work as I expected.
If I recompile the project once or twice and run, the Open window can show up without error. And when I modify my program here and there, this problem may not show up.
From here visual studio 2013 - Error message: wkernelbase.pdb not loaded - Stack Overflow
the suggestion is:
You probably trying to display image but image is actually not loaded in memory.
You are missing any header file of opencv and calling their functions in your code.
Indeed the image is missing. Where to find it?
So I want to try X64 now. But after I switched to X64, there are a lot of new compiling errors. I have to sort them out before to see if the Open still a problem.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
This is the image when it is right.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Can you build and run this sample? It runs fine for me in X64. Maybe something else is wrong in your code.
The message about wkernelbase.pdb can be ignored - that's just the debugger saying that it has no debug info for the point that got the error, which is probably an access violation due to wrong-type arguments being passed.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes, It works. But I can't convert the returned file name with this line:
character(512) :: fname
integer ret
...
ret = convertFtoCstring(fname,ofn%lpstrFile)
The error is:
Access violation reading location 0xFFFFFFFFEAF20000.
Thanks.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Well, that's your own routine. If you'll provide a small but complete test case, I'll look at it. Do you understand that the lpstrFile component is a pointer, and you must provide allocation for it?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I just added my line at the end of the demo.
There is:
character(512) :: file_spec = ""C
ofn%lpstrFile = loc(file_spec)
I realized I do not need this conversion. This file_spec is the returned file name I needed. It seems work. Also for my Win32 program.

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page