Ver Mensaje Individual
  #1 (permalink)  
Antiguo 14/06/2009, 20:48
Avatar de juaco14
juaco14
 
Fecha de Ingreso: mayo-2009
Mensajes: 185
Antigüedad: 15 años
Puntos: 1
Crear txt vacio

Hola.
Mi problema es que no puedo crear varios archivos vacios en la carpeta de origen del exe cuando se cargue el form.
El codigo que tengo pero no funciona es :

Código:
Private Sub Form1_Load()


If ArchivoExiste("\MarzoAbril.txt") Then GoTo EX
If ArchivoExiste("\Mayo.txt") Then GoTo EX
If ArchivoExiste("\Junio-Julio.txt") Then GoTo EX
If ArchivoExiste("\Agosto.txt") Then GoTo EX
If ArchivoExiste("\Septiembre-Octubre.txt") Then GoTo EX
If ArchivoExiste("\Noviembre-Diciembre.txt") Then GoTo EX

Set fs = CreateObject("Scripting.FileSystemObject")
Set a = fs.CreateTextFile("\MarzoAbril.txt", True)

Set fs = CreateObject("Scripting.FileSystemObject")
Set a = fs.CreateTextFile("\Mayo.txt", True)

Set fs = CreateObject("Scripting.FileSystemObject")
Set a = fs.CreateTextFile("\Junio-Julio.txt", True)

Set fs = CreateObject("Scripting.FileSystemObject")
Set a = fs.CreateTextFile("\Agosto.txt", True)

Set fs = CreateObject("Scripting.FileSystemObject")
Set a = fs.CreateTextFile("\Septiembre-Octubre.txt", True)

Set fs = CreateObject("Scripting.FileSystemObject")
Set a = fs.CreateTextFile("\Noviembre-Diciembre.txt", True)


EX:

End Sub

Gracias!