But I do not now if that will make a difference. The only way forward is to use the debugger and check exactly what happens at each point. You could also try setting the operation to "open", rather than NULL.
The method you uses does the following.
1. Determine the type of file using the extension.
2. Look up what application the OS (windows) has recorded to open that type of file.
3. Open the file using the application.
However if 1 fails, in that the file type is not known (already specified) then it will ask you for what to open it with.
If you want to explicitly specify some application to open the file with then you need a different method.
If you want to preclude the message in the first place then you will need to write code that first detects if the type is known. However that can still be problematic because if there is a known application for type, and then the application is uninstalled (or otherwise not available) there is no assurance that the type will have been unregistered. So it might still fail to open it.
The strange thing is that this behaviour is present on some PC, and on some PC are not present... and I noticed this behaviour even on Outlook application, on some image attachments ... so, guess is PC issue, not application issue.
For those new to message boards please try to follow a few simple rules when posting your question.
1. Choose the correct forum for your message. Posting a VB.NET question in the C++ forum will end in tears.
1. Define exactly what you mean.
2. If you mean at the application level then analyze the application to find how input is handled. If at the OS level then read up on how to create input handlers (drivers.) Depending on what 'key' you want to disable then this might require different approaches.
3. Write the code
4. Test it.
Yes, you can use CreateEvent, change the folder, set its value in lpParam, then SetEvent to let the thread to reread lpParam and continue to work with a new folder.
Note, that thread must now wait for multiple objects!