FORUMS PROFESSIONNELS
WINDEV
,
WEBDEV
et
WINDEV Mobile
Accueil
|
Messages récents
|
Connexion
|
Déconnexion
|
Français
Accueil
→
WINDEV 2024
→
ISEC
ISEC
Débuté par Ashury, 10 sep. 2008 11:40 - 3 réponses
Connectez-vous…
Ashury
#1
Posté le 10 septembre 2008 - 11:40
Hello of all,
Can I execute the following WinDev command under Windows XP:
ShellExecute("Dir", "C:\Refrence\samp.txt > C:\temp\samp_lx.txt")
Thanks,
Signaler
0
0
Michael ZEISS
#2
Posté le 10 septembre 2008 - 20:55
Hello Ashury,
I don't think so, that it could work in this way. As the OS-Command Dir is part of the OS ( in fact cmd.exe ), it should work with a .cmd file ( batch file ), where you have the dir command in it and then call
ShellExecute("cmd.exe", "/C <path and filename of the batch>")
Greetings
Signaler
0
0
Jimbo
#3
Posté le 11 septembre 2008 - 09:39
Hi, imho ShellExecute() is used to open a program by its extension - which should correspond to to a certain piece of, uh, software on the user's computer. E.g.: ShellExecute("\Users\MyName\MyLetter.doc") will start the application which is linked to .doc files and open the referenced document. This could be Word (Microsoft Office) or Write (Open Office). Depends on your computer ..
Your misunderstanding seems to stem from the SHELL command of some other (DOS?) programming languages, which is used there to call the console (XP, Vista: cmd.exe) and automatically execute console commands.
This will not work on Vista anymore! Neither users with admin rights nor ordinary users are allowed to execute a SHELL command !
What you can safely do: Programmatically fWrite(..) a batch file (e.g. mycopy.bat) to a 'safe' directory (\Users\.. or \Benutzer in German) and after that execute this batch file by use of the ExeRun(..) command.
Please, read the Help of WinDev !
Kind regards
Guenter
Signaler
0
0
Ashury
#4
Posté le 11 septembre 2008 - 15:02
Hi Günter,
Thanks,
Signaler
0
0
→ Revenir à WINDEV 2024
WINDEV 2024
WEBDEV 2024
WINDEV Mobile 2024
WINDEV (précédentes versions)
Français
English
Español
Portuguesa
Fermer cette fenêtre
Type de recherche
Uniquement les sujets
Tous les messages
Période de recherche
Date indifférente
Moins d'une heure
Moins de 24 heures
Moins d'une semaine
Moins d'un mois
Moins d'un an
Annuler
Aperçu de votre message
Ajouter une image
Importer une image depuis une URL
Envoyer une image depuis un fichier de votre disque
Déposez ici un fichier ou cliquez sur "Parcourir..."
ou
Annuler
0%
WLangage
SQL
XML, HTML
JAVA, Javascript
Texte