>Hello George:
>
>My application involves workgroups in an office environment where the group is working on a project. There are documents associated with the project. My form allows a user to select which documents are associated with a particular project. For this aspect of it, GETFILE()is fine. Other users would then have the ability to click on the document name to launch the underlying application in order to work with the document. I can't use GETFILE()for this part since the documents may be in more than one directory and even if I required the documents to be in the same direcory, I can't be selective about which documents show up in the Open File Dialog Box other than by their extensions. I would like the icons for application identification purposes and in order to be generally consistent with Windows. I am not familiar with the Common Dialogs Active X. Is is shipped with VFP6?
>I appreciate your help.
Hi Jay,
AFAIK, the control has been shipped with VFP since it first came out. The control. I first ran into it in VB 3.0 (yes, that's Visual Basic) which preceeded VFP 3.0.
One of its properties (.InitDir) allows you to specify the default directory that the dialog displays. In this way, it's more flexible than GETFILE(). It does display the icons that the user has associated with the files. Normally, these are set by default, but don't that the user can change these.
In this situation, I'd use the ShellExecute() API call. You can find examples of its use here in the download section. You might want to look at my File Runner program, which uses it. If the file isn't associated with a particular application, it launches the "Open With..." dialog.
hth,
George
Ubi caritas et amor, deus ibi est