Ir para conteúdo

POWERED BY:

Arquivado

Este tópico foi arquivado e está fechado para novas respostas.

Morpheus#2005

dts + fso

Recommended Posts

Como gravar todas as informações dentro de um txt ??

 

Tá brabo !!!

 

Só gravo a ultima informação da busca no banco ???

 

Obrigado por qualquer luz !!!!

 

 

 

 

Do while Not oRS.EOF
						
		
			   DTSGlobalVariables("ID").Value = oRS.Fields(0).Value

				DTSGlobalVariables("ID_Solicitante_Viagem").Value =  oRS.Fields(1).Value

		session.findById("wnd[0]").resizeWorkingPane 143, 27, False
		session.findById("wnd[0]").sendVKey 0
		session.findById("wnd[0]/tbar[0]/okcd").Text = "/XOTP"
		session.findById("wnd[0]").sendVKey 0
		session.findById("wnd[1]/usr/ctxtPTP40-PERNR").Text = DTSGlobalVariables("ID_Solicitante_Viagem").Value
		session.findById("wnd[1]/usr/ctxtPTP40-PERNR").caretPosition = 5
		
		
	 	
Dim fso, MyFile, FileName, TextLine

Set fso = CreateObject("Scripting.FileSystemObject")

' Open the file for output.
FileName = "c:\testfile.txt"

Set MyFile = fso.OpenTextFile(FileName, ForWriting, True)

' Write to the file.
MyFile.WriteLine DTSGlobalVariables("ID").Value
MyFile.WriteLine DTSGlobalVariables("ID_Solicitante_Viagem").Value

' Open the file for input.
Set MyFile = fso.OpenTextFile(FileName, ForReading)

' Read from the file and display the results.
Do While MyFile.AtEndOfStream <> True
	TextLine = MyFile.ReadLine
Loop
MyFile.Close

	oRS.MoveNext




loop	
	
		Set oRS = Nothing
	
		Main = DTSTaskExecResult_Success

Compartilhar este post


Link para o post
Compartilhar em outros sites

×

Informação importante

Ao usar o fórum, você concorda com nossos Termos e condições.