views:

152

answers:

2

Is it possible to programatically block users for accesing the context menu on files listed after showing an openfiledialog control that comes with the .net framework?

The intent is to block them from accessing "open" or "open with" and only allow them to pick a file from the list.

My only other idea is to build my own control instead of using System.Windows.Forms.OpenFileDialog

A: 

I would carefully look through the controls properties there is usually an option for this kind of thing.

Toby Allen
Already checked all the properties in the control and there are none.
jvanderh
+2  A: 

your quickest and most surefire bet in that situation would be to roll out your own OpenFileDialog.

Alternatives would be to try and capture the right-mouse-click on the open file dialog and not allow it to be processed

As a side note, I would be annoyed by a OpenFileDialog which does not behave like every other open file dialog out there (i.e. one that does not allow me to do tasks like renaming or "open with")

Stephen Wrighton