common dialog

  • Thread starter Thread starter Rosita
  • Start date Start date
R

Rosita

I'm trying to improve the funcionality of one of my forms adding a button in
the way that when the user click the button, it appears a window dialog to
select files. I think this is by a common dialog, and I've added this
control to my form, but I don't see any metod in the control for doing so.

Does anyone know how to do this?
 
Rosita said:
I'm trying to improve the funcionality of one of my forms adding a
button in the way that when the user click the button, it appears a
window dialog to select files. I think this is by a common dialog,
and I've added this control to my form, but I don't see any metod in
the control for doing so.

Does anyone know how to do this?

I suggest you don't bother with the CommonDialog control; it's not that
easy to use and it's subject to lots of version-related probloems.
Instead, call the Windows File Open/Save dialog directly, using the code
posted here:

www.mvps.org/access/api/api0001.htm
 
Another option is to use the FileDialog property of the Application object.
The following KB article is a good reference.

http://support.microsoft.com/default.aspx?scid=kb;en-us;279508

--
David Lloyd
MCSD .NET
http://LemingtonConsulting.com

This response is supplied "as is" without any representations or warranties.


I'm trying to improve the funcionality of one of my forms adding a button in
the way that when the user click the button, it appears a window dialog to
select files. I think this is by a common dialog, and I've added this
control to my form, but I don't see any metod in the control for doing so.

Does anyone know how to do this?
 
The KB article outlines the version issues. The user did not state the
version they were using. I simply posted it as another alternative the user
may want to consider. The user did not indicate anything about file saving,
so I did not address the issue.

--
David Lloyd
MCSD .NET
http://LemingtonConsulting.com

This response is supplied "as is" without any representations or warranties.


David Lloyd said:
Another option is to use the FileDialog property of the Application
object. The following KB article is a good reference.

http://support.microsoft.com/default.aspx?scid=kb;en-us;279508

Yes, if it's available in the version of Access you're using, or
targeting. It was introduced in Access 2002. Bear in mind, also, that
the Access version of Application.FileDialog won't let you open the File
Save dialog.
 
David Lloyd said:
The KB article outlines the version issues. The user did not state
the version they were using. I simply posted it as another
alternative the user may want to consider. The user did not indicate
anything about file saving, so I did not address the issue.

Sorry, I didn't mean to sound like I was disputing or denigrating your
suggestion. I just wanted to point out the additional consderations.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top