Agent to move files to sql

We have a lengthy agent that creates 7 .txt files on the domino server. The last step it to move them from the domino server to an sql server.

We have code that WORKS if you run it manually, but gives an ‘Illegal function called’ error if it is scheduled. We’re thinking it is some sort of permission issue? Any ideas?

The below batch line contains:

c:\windows\system32\ftp.exe -s:Ftp_NotesToSql_parm.txt > Ftp_NotesToSql.log

The last script lib in the agent is this:

Static Public Function Execute_Batch()	

	Dim batch As Variant	

	directory$="F:\etmrs\"

	Chdir directory$

	file$=Dir$("*.bat",0)	

	While file$<>""

		Print Cstr(file$)

		temp=file$

		file$=Dir$()

	Wend	

	batch=Shell("F:\etmrs\"&temp)	

End Function

Subject: Agent to move files to sql - solution

The server it was running on was a Windows NT server. When the notes db was moved to a Windows server, it worked. (Maybe we could have left it on the NT box if we’d have changed C:\Windows to C:\WinNT?).

Subject: Agent to move files to sql

If you’re trying to FTP files around using LotusScript I’d suggest you take a look at the NotesFTP library (http://www-10.lotus.com/ldd/sandbox.nsf/0/9e752a60b6f902c7852568ef006b4ad1?OpenDocument). It’ll give you much more flexibility and control over what you’re doing and make things much easier to debug.

HTH