MVS Fixed Records - WeOnlyDo Discussion board

MVS Fixed Records (General questions)

by cvmbor, Wednesday, May 23, 2007, 23:42 (6393 days ago)

As IBM mainframes deal largely with fixed length files we are sensitive to the FTP default process of lopping off trailing spaces from a record. We use pad(z) ASA and TRAIL FTP options to preserve these trailing blanks. How is that accomplished in WodSFTPdll?

Thanks

Craig Morris

Re: MVS Fixed Records

by woddrazen, Wednesday, May 23, 2007, 23:51 (6393 days ago) @ cvmbor

Hi Craig,


I'm not exactly sure what you want to accomplish but if you want to send some command to FTP Server to enable something than you can use wodFtpDLX RawSend Method.

Here is Example:
[code]
Ftp1.RawSend( SOME COMMAND & VbCrLf)
[/code]

More help for RawSend Method you can find here:
http://www.weonlydo.com/FtpDLX/Help/wodFtpDLXLib~wodFtpDLX~RawSend.html

Let us know how it goes.


Regards,
Drazen

Re: MVS Fixed Records

by cvmbor, Thursday, May 24, 2007, 14:48 (6393 days ago) @ woddrazen

As IBM mainframes deal largely with fixed length files we are sensitive to the FTP default process of lopping off trailing spaces from a record. We use pad(z) ASA and TRAIL FTP options to preserve these trailing blanks. How is that accomplished in WodSFTPdll?

Thanks

Craig Morris

Thanks the RawSend worked well setting the additional parameters required. I am trying to use RawSend again for an FTP process that cannot use the standard LIST remotePath command but requires a CWD (Change Directory) before a standalone LIST. This works OK if I step thru the code but if not the ListDir gets the 250 from by CWD and fails. I tried the pretranslate reply method to capture the 250 and set to zero but no luck. Whould you have a suggestion here?

Thanks

Craig Morris

Re: MVS Fixed Records

by wodDamir, Thursday, May 24, 2007, 16:09 (6393 days ago) @ cvmbor

Hi Craig,

Can you send me an FTPReply Event dump?

Also, i would suggest you try setting ListParams Property to . By default, wodFtpDLX tries to send LIST -al. The ListParams Property allows you to customize which parameters are sent when sending LIST command.

Please try it out and let me know the result.

Regards,
Damba

Re: MVS Fixed Records

by cvmbor, Friday, May 25, 2007, 04:40 (6392 days ago) @ wodDamir

Hi Craig,

Can you send me an FTPReply Event dump?

Also, i would suggest you try setting ListParams Property to . By default, wodFtpDLX tries to send LIST -al. The ListParams Property allows you to customize which parameters are sent when sending LIST command.

Please try it out and let me know the result.

Regards,
Damba

So indeed I was already using the ListParams trick. I connect and just before I issue the ListDir I issue my CWD command which returns the 200 Command OK. I have code in Done and Pretranslate to capture a 40200 and I change the code to 0 but I get a Run Time Error 40200 Command OK.

Not sure what dump you request. I put a debug print in Pretranslate so you could see the command issued

STATECHANGE to Connecting to server (from Disconnected from server)
Reply => 220-TCP/IP for VSE FTP Daemon Version 01.05 D 03/16/04 12.26
Copyright (c) 1995,2003 Connectivity Systems Incorporated
220 FTPD ready for new user.
STATECHANGE to Sending authentication data (from Connecting to server)
Command in => USER

Command out => USER

Reply => 331 User name okay, need password.
Command in => PASS

Command out => PASS

Reply => 230 User logged in, proceed.
Command in => FEAT

Command out => FEAT

Reply => 211-Supported extensions:
AUTH TLS
PBSZ
PROT
211 END
Command in => PWD

Command out => PWD

Reply => 257
STATECHANGE to Connected to server - idle (from Sending authentication data)
STATECHANGE to Downloading directory list from the server (from Connected to server - idle)
STATECHANGE to Setting transfer mode (from Downloading directory list from the server)
Command in => TYPE A

Command out => TYPE A

Reply => 250 Requested file action okay, completed.
STATECHANGE to Downloading directory list from the server (from Setting transfer mode)
STATECHANGE to Getting secondary data channel (from Downloading directory list from the server)
Command in => PASV

Command out => PASV

Reply => 200 Command okay.
STATECHANGE to Connected to server - idle (from Getting secondary data channel)


Re: MVS Fixed Records

by wodDamir, Friday, May 25, 2007, 16:35 (6392 days ago) @ cvmbor

Hi Craig,

The FtpReply looks ok to me.

What version of the component are you using?

Can you please update to the latest version and try it out? If I recall right that issue should be solved in the latest version.

Or you could try setting PasvPort Property to 0?

Can you try it and tell us of the result?

Regards,
Damba

Re: MVS Fixed Records

by cvmbor, Saturday, May 26, 2007, 05:29 (6391 days ago) @ wodDamir

Hi Craig,

The FtpReply looks ok to me.

What version of the component are you using?

Can you please update to the latest version and try it out? If I recall right that issue should be solved in the latest version.

Or you could try setting PasvPort Property to 0?

Can you try it and tell us of the result?

Regards,
Damba

So I just got the software last week but also got an email for a new upgrade so I installed. Tried the pasvport as well but still the 40200 error. My relevant code.

Sftp1.ListParams =
Sftp1.remotePath = ld_remotePath
Sftp1.RawSend CWD & Sftp1.remotePath & vbCrLf
Sftp1.PasvPort = 0
Case Else
Sftp1.remotePath = ld_remotePath
End Select

listDirResults =

Sftp1.ListDir

I also get rid of the directory in the list command.

But if I put a control break at the pasvport command and wait a few seconds then step thru the ListDir it works fine. I tried a Sleep (5000) here but no luck. The doc says the rawsend doesn't wait or trigger the events so is there some other way to let the rawsend pass without affecting the other commands?

Re: MVS Fixed Records

by wodDamir, Saturday, May 26, 2007, 16:35 (6391 days ago) @ cvmbor

Craig,

Maybe you could use the Done Event to issue RawSend Call? You can check the state, and if you're idleing, then send, otherwise not.

But I'm a bit confused why you're executing CWD at all. You should be able to use full paths on the server, without the need to change directory each time.

Maybe you could provide us with the access to the server in order for us to connect there and duplicate the issue you have?

If that's possible, you can send is the account info to techsupport@weonlydo.com

Regards,
Damba