473,322 Members | 1,408 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,322 software developers and data experts.

OpenFileDialog

I'm using the dialog as a file selector function. I want the dialog to stay
open until the user Cancels. If I build my own handler for the FileOK event
that does nothing, will anything else in the dialog's innards get screwed
up?

Ken
Nov 17 '05 #1
3 3050
Since the FileOK event uses a CancelEventHandler, I don't think anything
will go wrong if you cancel the operation.

-Atul, Sky Software http://www.ssware.com
Shell MegaPack For ActiveX & .Net - Windows Explorer Like Shell UI Controls


"Ken Kast" <ke*@NOSPAMkenkast.com> wrote in message
news:uI**************@TK2MSFTNGP14.phx.gbl...
I'm using the dialog as a file selector function. I want the dialog to
stay open until the user Cancels. If I build my own handler for the FileOK
event that does nothing, will anything else in the dialog's innards get
screwed up?

Ken

Nov 17 '05 #2
A new question:

I have a form with an OFD control. I'm senfing OFD a filter thus: "Text
files|*.txt|All files|*.*", with FilterIndex=1. Everything shows OK. But if
I change the filter at the bottom of the dialog to the second choice, the
control does not repaint, i.e., I just have a blank display. If I press the
Open button, then the control repaints and displays the correct files
relative to the filter. This same thing happens if I do a local new OFD
rather than have it as a control.

Can anyone tell me what's going on and what I can do to make it work right?

Ken
Nov 17 '05 #3
A new question:

I have a form with an OFD control. I'm senfing OFD a filter thus: "Text
files|*.txt|All files|*.*", with FilterIndex=1. Everything shows OK. But if
I change the filter at the bottom of the dialog to the second choice, the
control does not repaint, i.e., I just have a blank display. If I press the
Open button, then the control repaints and displays the correct files
relative to the filter. This same thing happens if I do a local new OFD
rather than have it as a control.

Can anyone tell me what's going on and what I can do to make it work right?

Ken
Nov 17 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Jody Gelowitz | last post by:
VS.NET 2002 and 2003 are installed. ..NET Framework 1.0 and 1.1 installed Program running under VisualBasic.NET 2002 with .NET Framwork 1.0 I am experiencing a problem with ADO.NET where the...
3
by: bobrad | last post by:
MAYBE SOMEBODY CAM HELP I AM USING THE FOLLOWING CODE TO GET A LOCATION OF A FILE IN A WINFORM DIALOG OpenFileDialog openFileDialog = new OpenFileDialog(); OpenFileDialog.Filter = " Access...
2
by: don | last post by:
has anyone experienced problems with interactions between OpenFileDialog and FileStream? When I select "open" from an OpenFileDialog the subsequent calls to FileStream do not create a file. If I do...
4
by: Nagachandra Sekhar Grandhi | last post by:
I am facing a problem with OpenFileDialog. It is as follows. I opened OpenFileDialog dialog box and selected a folder in it. After selecting the folder when i tried to delete the same folder in...
8
by: e-mid | last post by:
why does not openFileDialog have closed event? i want to do something; as soon as the dialog closes. is there a way to do this?
6
by: barbara_dave | last post by:
Hi, All, I want to use the openfiledialog to open different extension files in different directory( only one type files at one time). I set the OpenFiledialog InitialDirectory and Filter...
8
by: marcus.kwok | last post by:
I am having a weird problem and I have can't figure out why it is happening. I create an OpenFileDialog and set a filename filter. When the dialog first opens, the filter works correctly, and...
1
by: sam | last post by:
OpenFileDialog appears to be "holding onto" the parent folder of a selected file until the application using the dialog quits. After creating a folder containing a file, I attempted to select...
3
by: Martijn Mulder | last post by:
It strikes me that System.Windows.Forms.OpenFileDialog seems te 'remember' which directory it was in last, even when a new OpenFileDialog-object is created for every access to the file system....
0
by: mbewers1 | last post by:
Hi I'm having a problem trying to get a customised OpenFileDialog() to fulfil my requirements. The code for this custom-built dialog has been taken from another site...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.