I'm developing an GUI-Application with C#.
In this application i like to use edtftpnet 1.1.5 to send a kind of batchfile (JCL - Job Control Language) to a MVS-Host, which should be executed immidiately.
Using ftp (IBM) on a command line looks like this (line numbers inserted):
Microsoft Windows XP [Version 5.1.2600]
(C) Copyright 1985-2001 Microsoft Corp.
01 c:\>ftp myhost
02 Connection with myhost created.
03 220-TCPFTP1 IBM FTP CS V1R2 at myhost, 15:12:11 on 2005-03-07.
04 220 Connection will close if idle for more than 5 minutes.
05 User (myhost:(none)): myuser
06 331 Send password please.
07 password: *********
08 230 myuser is logged on. Working directory is "myuser.".
09 ftp> quote site filetype=jes
10 200 SITE command was accepted
11 ftp> put d:\mydir\select2.jcl
12 200 Port request OK.
13 125 Sending Job to JES internal reader FIXrecfm 80
14 250-It is known to JES as JOB12715
15 250 Transfer completed successfully.
16 FTP: 64d Bytes gesendet in 0,00Sekunden 9266000,00KB/s
17 ftp> bye
18 221 Quit command received. Goodbye.
Important are the lines 09 and 11.
Using edtftpnet i do the following within my GUI-Application:
01 FTPClient ftp = null;
02 ftp = new FTPClient(mHost.Text);
03 ftp.Login(mUser.Text, mPwd.Text);
04 string[] vc = {"200"};
05 string s;
06 s = ftp.Quote("site filetype=jes", vc);
07 MessageBox.Show(s);
08 ftp.Put(mJclFile.Text, null);
09 ftp.Quit();
The Quote-Method in line 06 returns ok ("SITE command was accepted").
But the put-Method in line 08 does not succeed.
It throws an EnterpriseDT.Net.Ftp.FTPException: "Invalid data set name. Use MVS Dsname conventions".
But: As far as I know, i may not set the name of the remotefile as suggested.
Any ideas what to do???
(and excuse my english)