Home All Groups Group Topic Archive Search About

Extending OpenFileDialog to add a picture preview?

Author
23 Sep 2006 5:13 PM
Michael A. Covington
How easy is it to extend OpenFileDialog so that when a file is selected
(clicked), my code will be called to extract some information from the file
and display a picture?

Author
23 Sep 2006 7:54 PM
Sean Chambers
You could use the FileOk event of the OFD control. Then read the OFD
..FileName property. That would give you a path.

I'm sure there is a dozen other ways to do it, but this is how I would
probably accomplish that.

hope it helps!

Sean


Michael A. Covington wrote:
Show quoteHide quote
> How easy is it to extend OpenFileDialog so that when a file is selected
> (clicked), my code will be called to extract some information from the file
> and display a picture?
Are all your drivers up to date? click for free checkup

Author
23 Sep 2006 8:50 PM
Michael A. Covington
But FileOk occurs when the user clicks Open or Save, at which time he's
through with the dialog altogether.  I would like to call up the preview
picture when the user clicks once on any file.

Show quoteHide quote
"Sean Chambers" <dko***@gmail.com> wrote in message
news:1159041268.812003.61140@b28g2000cwb.googlegroups.com...
> You could use the FileOk event of the OFD control. Then read the OFD
> .FileName property. That would give you a path.
>
> I'm sure there is a dozen other ways to do it, but this is how I would
> probably accomplish that.
>
> hope it helps!
>
> Sean
>
>
> Michael A. Covington wrote:
>> How easy is it to extend OpenFileDialog so that when a file is selected
>> (clicked), my code will be called to extract some information from the
>> file
>> and display a picture?
>
Author
24 Sep 2006 12:27 AM
Michael Nemtsev
Hello Michael,

Look at this one http://www.codeproject.com/cs/miscctrl/FileDialogExtender.asp

MC> How easy is it to extend OpenFileDialog so that when a file is
MC> selected (clicked), my code will be called to extract some
MC> information from the file and display a picture?
MC>
---
WBR,
Michael  Nemtsev :: blog: http://spaces.live.com/laflour

"At times one remains faithful to a cause only because its opponents do not
cease to be insipid." (c) Friedrich Nietzsche



Post Thread options