none
Problem with the Preview pane in the OpenFileDialog RRS feed

  • Question

  • The Preview pane in the dialog seems to cause Word (which I have running and connected to my program) to disappear form the screen! It's actually still running, but not visibly. If I run Word from that point, it still contains any file that was open in it before.

    I think this is related to the Preview Pane setting in Windows Explorer. If Preview Pane is set ON there, it is ON in the OpenFileDialog. And when the Preview Pane is on in the dialog, it causes Word to disappear. (Probably this is related to the fact that the Preview Pane in my program is going to show the contents of Word files.)

    I checked the possible settings for the OpenFileDialog, and can't find anything that would turn the Preview Pane off. If I can't turn it off in the dialog, maybe I could turn it off in Windows Explorer. So, if anyone knows how to do that, it would help me almost as much as finding out how to turn the Preview Pane off in the dialog. (I could turn Preview off in Explorer, display the OpenFileDialog, then turn Preview back on in Explorer if it was on before.)


    Robert Homes



    • Edited by Robert Homes Tuesday, September 19, 2017 2:18 AM Added last sentence in parens
    Monday, September 18, 2017 12:59 PM

All replies

  • The Preview pane in the dialog seems to cause Word (which I have running and connected to my program) to disappear form the screen! It's actually still running, but not visibly. If I run Word from that point, it still contains any file that was open in it before.

    I think this is related to the Preview Pane setting in Windows Explorer. If Preview Pane is set ON there, it is ON in the OpenFileDialog. And when the Preview Pane is on in the dialog, it causes Word to disappear. (Probably this is related to the fact that the Preview Pane in my program is going to show the contents of Word files.)

    I checked the possible settings for the OpenFileDialog, and can't find anything that would turn the Preview Pane off. If I can't turn it off in the dialog, maybe I could turn it off in Windows Explorer. So, if anyone knows how to do that, it would help me almost as much as finding out how to turn the Preview Pane off in the dialog.


    Robert Homes


    Hi Robert,

    You said that the Preview pane in the dialog seems to cause Word (which I have running and connected to my program) to disappear form the screen!  How word disappear from screen?  What does it mean?

    Can you provide some code about this, so that I can test your code and know what problem you encounter.

    Best Regards,

    Cherry


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Tuesday, September 19, 2017 8:41 AM
    Moderator
  • Hi Cherry! Thanks for trying to help.

    I'm not sure if sending you any code would help. The problem is quite simple, Word just disappears when I select a file in the OpenFileDialog (when the preview pane is showing in the dialog). I'm running Word version 14, which I think is the 2010 version. I like that version because it doesn't create separate Word programs every time you open another file. To test my code, you would have to get Word 2010 running, make sure Preview Pane is enabled in Windows Explorer, and then run come code that calls up the dialog in a folder that has some Word files. I can still send you some code if you want to go through all that, but meanwhile I've found a partial solution that seems to work for me, as follows.

    I checked out other threads mentioned the OpenFileDialog and Preview Pane, and found a work-around in one of those. Someone suggested setting the dialog's  .AutoUpgradeEnabled property to False, which seems to return the dialog to a previous version that doesn't have a Preview Pane. That works! And I don't see any downside - yet, anyway.

    Looks like many others have had similar problems with the OpenFileDialog and the Preview Pane. I'm still interested to learn if there is some way to suppress the Preview Pane without going back to a previous version of the dialog, so if you know about something in that regard, please let me know. Or, as you asked, I can send you some sample code, though I don't think it will help much.

    BTW, you wondered about Word "disappearing". That's pretty simple. You can run Word (from VB) without displaying it. So I think what happens when it disappears is that it just goes into a state where the UI's visibility is set to false. Like I said before, I'm sure Word doesn't actually stop because if you run it again, it still has the file(s) that were active in it before it "disappeared."


    Robert Homes


    • Edited by Robert Homes Tuesday, September 19, 2017 11:36 AM added a couple words to fix typo
    Tuesday, September 19, 2017 11:33 AM
  • Hi Robert,

    Sorry that I can not reproduce this issue, the content in the word did not disappear in my test:

    I'm afraid it is not a public issue, I tested it with different computers but all of them can not reproduce it.

    Best Regards,

    Stanly


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Wednesday, September 20, 2017 9:42 AM
  • I can't tell exactly what is happening in your video, so I don't know if you reproduced exactly my situation. Thanks, anyway.

    Robert Homes

    Wednesday, September 20, 2017 1:32 PM
  • Hi Robert,

    You said that you run word firstly, then  use OpenFileDialog and the Preview Pane, the word disappear, but I can not reproduce this issue, my word don't disappear. I use 2016 word.

    Best Regards,

    Cherry


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Thursday, September 21, 2017 9:10 AM
    Moderator
  • Not sure, but I think that only happens when there is a Word document present in the folder that the OpenFileDialog is looking at, and the Preview Pane displays that document. I'm using Word 2010.

    Robert Homes

    Thursday, September 21, 2017 11:33 AM
  • I can't tell exactly what is happening in your video, so I don't know if you reproduced exactly my situation. Thanks, anyway.

    Robert Homes

    Hi Robert,

    I mean as the gif you can see, in my test, the content can be show up normally when click the preview pane in the explorer:

    I'm afraid the issue you are experiencing is not a common problem, maybe try to update your Word to another version.

    Regards,

    Stanly


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Friday, September 22, 2017 7:56 AM