1. se copiaza executabilul windows HAPLICXX.EXE in catalogul H: langa celelalte executabile.
2. se creeaza o procedura cu acelasi nume (fara extensie si litere mari) HAPLICXX, tot in H:,
vezi continutul mai jos, nu trebuie adaptat nimic
3. se introduce in aplic numele procedurii HAPLICXX si celelalte elemente,
depinde daca executabilul este de tip HAMOR Soft sau nu.
Atentie:#!/bin/bash
#Bash de pornire executabil Windows prin hWTOOLS
#Adaptat la mediul LINUX_WP
#In APLIC avem inscrisa aplicatia WAPLICxx in loc de HAPLICxx
#si se va porni executabilul HAPLICxx.EXE in Windows prin hWTOOLS
#Variabile
#Catalogul executabilului in format Windows
#Din /HAMOR/hamor/hDATA/HIMSS_60 -> face H:\hDATA
WINDIR0=$(dirname $0)
WINDIR1=${WINDIR0/$H/H:}
WINDIR=${WINDIR1//\//\\}
#Nume script WAPLICxx
FILEN=$(basename $0)
#Nume fisiere EXE se transforma WAPLICxx in HAPLICxx
HFILNAME=H${FILEN:1}.EXE
#Nume si path baza de date in format Windows
WINDB0=$1
WINDB1=${WINDB0/$H/H:}
WINDB=${WINDB1//\//\\}
#echo $WINDIR
#echo $WINDB
#echo $FILEN
#echo $HFILNAME
#read -p "Press [Enter] key to start program..."
echo "[RUN] " > $USERHOME/RW/TMP/$FILEN.CMD
echo "MODE=/MAX " >> $USERHOME/RW/TMP/$FILEN.CMD
echo "DIRECTORY="$WINDIR >> $USERHOME/RW/TMP/$FILEN.CMD
echo "EXE="$HFILNAME >> $USERHOME/RW/TMP/$FILEN.CMD
echo "PARAMETERS="$WINDB >> $USERHOME/RW/TMP/$FILEN.CMD
mv $USERHOME/RW/TMP/$FILEN.CMD $H_SCAT/$FILEN.CMD
daca programul windows face actualizaru in baza de date asupra careia opereaza,
in parelel nu trebuie sa se execute programe Linux care modifica aceeasi baza de date,
pentru ca blocarile intre windows-Linux nu functioneaza correct.