Ver Mensaje Individual
  #2 (permalink)  
Antiguo 10/02/2002, 13:09
Avatar de Aston
Aston
 
Fecha de Ingreso: mayo-2001
Ubicación: Madrid
Mensajes: 933
Antigüedad: 24 años
Puntos: 0
Re: crear archivos de texto con asp

Hola, en esta función sólo debes pasarle el nombre del archivo y su contenido y asunto resuelto.

<pre>
Sub NuevoArchivo(cArchi, cCuerpo)
'Crea o modifica un archivo de texto
Dim oSFile, oTextArch

Set oSFile = Server.CreateObject(&quot;Scripting.FileSystemObje ct&quot;)
Set oTextArch = oSFile.CreateTextFile (Server.MapPath(&quot;Archivos/&quot; &amp; cArchi &amp; &quot;.txt&quot;), True)
oTextArch.WriteLine(cCuerpo)

Set oSFile = Nothing
oTextArch.Close: Set oTextArch = Nothing
End Sub
</pre>

Espero te ayude, un saludo. ;)

<a href="http://www.laventanita.net/" target="_blank">
<img src="http://www.breogan.org/images/Aston.gif" border="0" alt="La Ventanita.net - Lo imprescindible en la red"></a>