Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Getfile - Alternative Needed
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00182231
Message ID:
00182314
Vues:
40
>I have a subdirectory and want to allow users to retrieve either a .bmp OR .gif file name similar to the getPic function call. I thought I read somewhere there is a better get file (activex maybe?) in vfp6? Currently I can't get it to go to the path I want without:
>
>cd graphics
>lcFile = getFile('bmp')
>cd ..
>
>I want:
>lcFile = getfile('bmp,gif', 'graphics') or similar
>where graphics is the subdirectory.
>

Robert, you might want to look at modifying the Enhanced GetDir() I posted in the FAQ, which is based on using the Shell.Application automation object; Shell.Application's BrowseForFolder method will allow the selection of files as well as folders by setting the BIF_BROWSEINCLUDEFILES value in the ulFlags argument (see the source for the values.) You can specify a starting folder with the RootFolder parameter. Play with the function I posted, if you have access to the MSDN, look at the Shell Object topic as a starting place.

To use the file selection option, you need to have at least version 4.71 of COMCTL32.DLL and SHELL32.DLL on the system, which are distributed with IE 4.

>Any help would be appreciated...
>Robert
EMail: EdR@edrauh.com
"See, the sun is going down..."
"No, the horizon is moving up!"
- Firesign Theater


NT and Win2K FAQ .. cWashington WSH/ADSI/WMI site
MS WSH site ........... WSH FAQ Site
Wrox Press .............. Win32 Scripting Journal
eSolutions Services, LLC

The Surgeon General has determined that prolonged exposure to the Windows Script Host may be addictive to laboratory mice and codemonkeys
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform