>&&&& Name and Location of the PCA host configuration file >cRecibir = "c:\Program Files\Symantec\PcAnywhere\Data\Hostfile.BHF" >**** >#DEFINE SW_HIDE 0 >#DEFINE SW_NORMAL 1 >#DEFINE SW_MINIMIZED 2 >#DEFINE SW_MAXIMIZED 3 > >cComando = Alltrim(Trarun.comando2) >cRecibir = Alltrim(Trarun.Recibir) >oShell=CREATEOBJECT("WSCRIPT.SHELL") > >&&& The next line of code launch PCA and wait till program exit >oShell.Run(cRecibir, SW_NORMAL, .T.) > >! &cComando &&&& This line run Winzip to decompress the data > >THISFORM.COPIARINV(2) &&& Method to copy the downloaded data > >Close Data All >********************************************** > >MESSAGEBOX("*** DATA TRANSFERED ***",0,"DATA TRANSFER") >Thisform.Release > >>
>#DEFINE SW_HIDE 0 >#DEFINE SW_NORMAL 1 >#DEFINE SW_MINIMIZED 2 >#DEFINE SW_MAXIMIZED 3 > >ThisForm.Copiardesde1.Enabled=.f. >This.Enabled=.f. > > >THISFORM.COPIARINV(1) &&& Method to extract the data from the VFP Tables > >cComando = Alltrim(Trarun.comando) &&& set the command line for Winzip >Close Data All >************************************************************* >! &cComando &&& Launch Winzip to compress the files > >oShell = CREATEOBJECT("WSCRIPT.SHELL") > > >*** set the location & file name of file to send >cEnviar = Alltrim(Trarun.Enviar) > >If File(cEnviar) > oShell.Run(cEnviar,SW_NORMAL,.t.) &&& Establish PCA Conn. >Else > MESSAGEBOX("*** FILE NOT FOUND ***",16,"DATA TRANSFER") >Endif > >MESSAGEBOX("*** PROCESS ENDED ***",0,"DATA TRANSFER") >Thisform.release >>