Information générale
Catégorie:
Codage, syntaxe et commandes
I make a exe from the following code which works well for updating across a network. The user starts this program which checks file versions updates if needed then starts your program. Just need to make sure they always run from this not the actual program.
SET TALK OFF
SET SAFETY OFF
** Check can access network by looking for a file ( I map to x: )
IF !FILE("x:\somefile.dbf")
MESSAGEBOX("Network not connected",48,"Warning")
QUIT
endif
** Compare file version on network with local file and copy if different
lsexe = "x:\yourprog.exe"
ltexe = "yourprog.exe"
AGETFILEVERSION(tarr, ltEXE)
AGETFILEVERSION(sarr, lsEXE)
IF tarr[4]#sarr[4]
COPY FILE &lsEXE TO <EXE
endif
RUN/N1 <EXE && run the program as separate process
IF ".EXE" $ SYS(16)
QUIT
ELSE
Cancel
ENDIF
Précédent
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement