views:

45

answers:

1

I know this is normaly implemented with a temp file but this wont work here since we are dealing with pretty large files stored in a database.

so far my idea is to create a small temp file that has a unique name and do a FileSystemWatcher monitoring the drop to get the path. but this doesnt seem optimal eighter.

are there any other ideas you guys could point me to?

maybe with virtual files? if so - how?

will be greatful for any hint.

thanks.

+2  A: 

What you're looking for is a fully functional implementation of IDataObject. See http://www.codeproject.com/KB/dotnet/DataObjectEx.aspx for an example of how this can be achieved. This implementation allows you to provide a MemoryStream which contains the actual file drag/drop contents.

Pieter
Interesting, I'll keep that in mind for future projects.
testalino
Exactly. Thany you. Also have a look here http://blogs.msdn.com/b/delay/archive/2009/10/26/creating-something-from-nothing-developer-friendly-virtual-file-implementation-for-net.aspx
GuyFawkes