views:

94

answers:

2

I am looking for a control to be able to embed the functionality of the FileOpenDialog without the idea of using a modal dialog. Does something like this exist already? (ideally within .Net 2.0 framework, C#).

+1  A: 

I haven't come across one, but I had to do something quite like what you're suggesting for my most recent project. What I did was make a way to select files in a dropdown from a DataGridView, but it can easily be adapted to what you're looking for.

There is an excellent example on CodeProject about how to make a ListView that looks like the standard one in the FileOpenDialog. It uses a bit of P/Invoke to get the system image list and you might have to fiddle with it yourself to get it working right, but it's quite effective. I used this as a starting point and maybe it will help you start out in the right direction.

lc
A: 

Thanks. I saw this example but this is something that I can only rate as a nice to have vs a must-have. It would almost be worth doing since I could use it in other places as well but I can't justify it right now.

I did some more searching and didn't really run into anything like I was looking for.

I know what you mean. I bit the bullet because I needed to lock the user into a particular path and not let them change directories. That plus wanting to avoid the modal dialog was just enough to make it a necessity for me.
lc