Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How do open a file with its windows associated applicati
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00854613
Message ID:
00854616
Vues:
25
This message has been marked as a message which has helped to the initial question of the thread.
You can use the SHELLEXECUTE function in the windows shell API to launch the default application. There's a FFC class that encapsulates the functionality for you.
MODIFY CLASS _shellexecute OF (HOME() + 'ffc\_environ.vcx')
You can check the registry for the extension or just trap a return value < 32 from the shellexecute() method.

Cheers,

Andrew

>Is there a way that I can open a file from within a fox application and launch it with its associated application. For example, if i have a open dialogue box and i select a PDF file, the file will be open with acrobat reader.
>
>Also is there away I can check to see if the application to open the file is installed on the computer.
>
>Regards,
>
>Stuart


If we were to introduce Visual FoxBase+, would we be able to work from the dotNet Prompt?


From Top 22 Developer Responses to defects in Software
2. "It’s not a bug, it’s a feature."
1. "I thought I fixed that."


All my FoxTalk and other articles are available on my web site.


Unless specifically identified otherwise, anthing posted here is purely my opinion and may or may not reflect the policies or practices of Microsoft.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform