Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Generar archivo TXT...
Message
From
16/05/2003 13:56:46
 
 
To
16/05/2003 09:34:47
General information
Forum:
Visual FoxPro
Category:
CodeMine
Miscellaneous
Thread ID:
00789194
Message ID:
00789362
Views:
22
Tambien puedes crear los archivos con SET TEXTMERGE o TEXT TO ... ENDTEXT, me parecen opciones mas poderosas para crear archivos.
Como un pequeño ejemplo, te pongo el siguiente código.
   lcArchivo="Miarchivo.txt"
   SET TEXTMERGE ON
   SET TEXTMERGE TO (lcArchivo)
      \\Inicio de mi Archivo
      \\<<REPLICATE("*",80)
      *** Por ejemplo, recorremos la tabla de clientes
      SELECT Clientes
      SCAN
         \\Codigo Cliente: <<cCode>>
         \\Nombre: <<cName>>
         \\Direccion: <<cAddress>>
         \\Telefono: <<cPhone>>
         \\<<REPLICATE("-",80)>>
      ENDSCAN
      \\Fin de mi archivo
      \\<<REPLICATE("*",80)>>
  SET TEXTMERGE TO
  SET TEXTMERGE OFF
>Saludos.


>Desde versiones anteriores de Visual FoxPro, mi opcion para generar un archivo TXT ha sido la siguiente tecnika:
>set device to file &nomarchivo
>@1,1 say "mi primera linea"
>@2,1 say "mi segunda linea"
>set device to screen
>esto me ha funcionado muy bien, ahora me kuestiono si esta es una buena
teknika para la generacion de archivos TXT, alguien lo hace distinto?
Apoya a Visual FoxPro usandolo legalmente
--
¸,ø¤º°`°º¤ø,¸¸,ø¤º°`°º¤ø,¸¸,ø¤º°`°º¤ø,¸¸,ø¤º°`°º
Espartaco Palma Martínez
SysOp PortalFox
http://www.portalfox.com
esparta@portalfox.com
Previous
Reply
Map
View

Click here to load this message in the networking platform