Topic: ouvrir un fichier Excel
Bonsoir a tous
je viens d'arriver au Forum et me voila déjà avec une demande.
comment on peux ouvrir un fichier Excel avec MVDB
Merci pour votre aide
My Visual Database → General → ouvrir un fichier Excel
Bonsoir a tous
je viens d'arriver au Forum et me voila déjà avec une demande.
comment on peux ouvrir un fichier Excel avec MVDB
Merci pour votre aide
Hello Nicomax
Bienvenue dans MVD, un superbe programme de gestion de base de données
Pour ce faire, entrez cette instruction
A mettre derrière l'évènement OnClick d'un bouton :
OpenFile ('Z:\WIP\WIP.xls');
Dans ce cas, Excel se lancera et ouvrira le fichier WIP.xls
JB
Merci JB
JB
Bonsoir désolé
Quand tu dit "derrière l'évènement Onclick d'un bouton"
C'est dans Action des propriétés
Tu me confirme !
Hi Nikomax, Salut Jean,
Have a look at the screenshot in the attachment.
There are a couple of steps you need to take.
1. Make sure that you have 'scripting' turned on.
2. Select the object that you want to attach a procedure to in your script (in this example, a button).
3. In the 'Events' tab for the selected object, double-click on the particular 'event' that you want to use
4. This will automatically create an empty procedure for you in the Script editor and take you to the script editor where you can enter your code.
In the example, there are two procedures, one for each button.
For the first button, it opens a program (I've chosen 'notepad' but you can choose anything - Excel, Google etc etc).
For the second button, it opens a specific file.
Depending on where your program or specific file is located on your system, you may need to specify the path (as Jean showed you in his example).
Regards,
Derek.
Hello Nikomax, Hello Derek, how are you ith this strange weather ?
Niko,lpour utiliser cette instruction, tu vas dans l'Inspecteur d'Objets (sur la gauche), tu cliques sur Events (Evènements).
Ensuite depuis la liste d'évènements possibles, tu double cliques sur le premier (ONClick).
Et danslapage de scripts qui va s'ouvrir en te présentant cet évènement, tu colles l'instruction que je t'ai communiqué plus haut.
Cela donnera :
procedure Form1_Button1_OnClick (Sender: TObject);
begin
OpenFile('Covers'); // On accède au fichier des couvertures
end;
Reviens vers nous si tu rencontres des problèmes.
Dans tous les cas les solutions proposées par Derek sont toujours très efficaces.
En outre elles vont à l’essentiel, sans fioritures qui surchargeraient le code.
JB
Merci
Jean de ton aide
C'est claire maintenant, et ça marche.
Hello Derek
Thank you for your help it's clear now to me.
Niko
My Visual Database → General → ouvrir un fichier Excel
Powered by PunBB, supported by Informer Technologies, Inc.
Theme Hydrogen by Kushi