Latest News

the latest news from our team

NFT Release Notes

There are four sections to these notes:

  1. Installation

  2. Operation

  3. Support

  4. Network File Transfer’s OLE Automation Interface


Installation

The server portion of the Network File Transfer is self installing. The server portion must be installed once on each HP e3000 if the NFT server files have not been installed by another Minisoft Client Server application.

The Server Installation Utility will create the default Account, User and Group needed for NFT.


Operation

After the server programs have been uploaded to the HP e3000, the Network File Transfer server is started by streaming the file named “MSJOB.MM.MINISOFT”. This JOB must be running for Network File Transfer to operate.

:STREAM MSJOB.MM.MINISOFT

To disable the Network File Transfer, use the MSJOBCMD utility, use the Server Console Utility or abort the JOB from the console. Usually, streaming “MSJOB.MM.MINISOFT” should become part of your normal system startup procedures.

The file “MSJOB.MM.MINISOFT” contains the following line:

!SETVAR MSSERVER000002 “30001 0 NFTSRVR.MM.MINISOFT;PRI=DS S”

The first parameter in the string above contains a TCP/IP port number. This is any number between 1 and 32767. Each server using TCP/IP must have a unique port number. It is recommended that “30001” is used, since we have not found any other software on the HP e3000 that uses this number. All clients must set this same port number in their configuration in order to connect to the server program. If you wish to have more than one server active, then each server must have its own unique port number. Remember, that one server can service any number of clients simultaneously, so only one active server is required. You may, however, wish to have more than one server for accounting or security reasons.


Support

Please refer all requests for assistance to: <support@minisoft.com>


Network File Transfer’s OLE Automation Interface

Client programs can access MS92’s Network File Transfer (HP3000 MPE/iX) and/or FTP (Unix, etc…) module programmatically via OLE Automation. Any client may create a Session object and use the object’s properties and methods to communicate with the server program.

File Transfer Engine (HP3000 MPE/iX)

The File Transfer Engine objects are used by the client program to communicate with the file transfer server program on the host. This gives the client the ability to transfer files to/from the host as well as execute MPE commands, MPE command files and programs. In order to access the File Transfer Engine from a client program, the client program must create the Session object of the File Transfer Engine as follows:

Visual BASIC:

Dim FTSession As Object … Set FTSession = CreateObject(“NetFT.Session”)

Visual C++:

CreateDispatch( “NetFT.Session” );

When the client program wishes to stop using the File Transfer Engine, then it must delete the Session object as follows:

Visual BASIC:

Set FTSession = Nothing

Visual C++:

ReleaseDispatch();

Session Object

Once the Session object has been created the client can access its properties and methods to access the host’s file transfer server program. Typically the properties specifying the host’s IP address, TCP/IP port number, and login information are set, then the Connect method is called to connect the the host’s file transfer server program.

Property Reference

AccountPassword, type String, write access
   The string used for the account password when connecting to the host’s file transfer server program.

ConnectStatus, type Boolean, read access
   Contains True if the last connection attempt was successful, else False.

CtrlZIsEof, type Boolean, write access
   This property specifies whether the end-of-file of a PC file is marked with a CTRL-Z character or not. A value of True indicates that a CTRL-Z found in the file will be interpreted as the EOF on uploads, and that a CTRL-Z will be written at the end of the file on downloads. A value of False indicates that a CTRL-Z found in the file will be intepreted as normal data on uploads, and that a CTRL-Z will not be written at the end of the file on downloads. This property only applies to ASCII transfers. The default is False.

Direction, type integer, write access
   This property specifies the direction of the next file transfer. A value of 0 indicates uploading, while a value of 1 indicates downloading. The default is uploading.

DisplayStats, type Boolean, write access
   This property specifies whether a dialog box showing the status of the transfer should be displayed during the file transfer. The default is False.

ErrorMessage, type String, read access
   Contains the last error message generated

ErrorNumber, type integer, read access
   Contains the last error number generated.

ExistsAction, type integer, write access
   This property specifies what action to take if the destination file already exists. A value of 0 indicates that the transfer should be cancelled. A value of 1 indicates that the destination file should be deleted and the transfer should continue. A value of 2 indicates that the user should be prompted whether to delete the file or cancel the transfer. A value of 3 indicates that the destination file should be appended to. The default is 0.

FileTransferStatus, type integer, read access
  This property indicates the status an in-progress or completed file transfer. A value of 0 indicates that the last transfer was completed successfully. A value of 1 indicates that the last transfer failed. Any other value indicates that a file transfer or some other operation is in progress.

GroupPassword, type String, write access
   The string used for the group password when connecting to the host’s file transfer server program.

HostAddress, type String, write access
   The host name or IP address used when attempting to connect to the host.

HostFile, type String, write access
   This property specifies the name of the host file involved in the transfer. It may be fully qualified with the group and account if necessary. If the file is in or should be created in the temporary domain, the string “,TEMP” should be appended to its name.

HostFileList( String ListMask ), String, read access
   This property returns a comma delimited list of files on the host. The ListMask parameter specifies a valid LISTF filename argument used to compile the list with.

JobName, type String, write access
   The string used for the job name when connecting to the host’s file transfer server program.

KeepTrailingSpaces, type Boolean, write access
   This property specifies what to do with the trailing spaces on each record during ASCII downloads. A value of True indicates that trailing spaces should be kept, while a value of False indicates that trailing spaces should be deleted. The default is False.

LocalFile, type String, write access
   This property specifies the name of the local file involved in the file transfer. It may be fully qualified with the drive letter and path if necessary.

LoginAccount, type String, write access
   The string used for the account name when connecting to the host’s file transfer server program.

LoginGroup, type String, write access
   The string used for the group name when connecting to the host’s file transfer server program.

LoginInfo, type String, read access
   This property contains the current user name, group name, and account name the server is running from. The first 8 characters contain the user name, the next 8 characters contain the group name, and the last 8 characters contain the account name.

LoginStatus, type Boolean, read access
   Contains True if the login information supplied when connecting to the host’s file transfer server program was valid, else False.

LoginUser, type String, write access
   The string used for the user name when connecting to the host’s file transfer server program.

Port, type integer, write access
   A number that uniquely identifies the program on the host that the client wishes to connect to. This number is typically 31001 for the file transfer server, but may be any number between 1 and 32767.

RecordSize, type integer, write access
   This property specifies the record length of the host file for uploads. Valid values are between 1 and 4096. The default is 80 for ASCII transfers, or 256 for binary transfers.

SpacesPerTab, type integer, write access
   This property sets the distance between tab stops and enables changing tab characters to spaces to fill to the next tab stop. It is used only on ASCII uploads. A value of 0 disables the replacement of tab characters. Valid values are between 0 and 9. The default is 0.

TransferMode, type integer, write access
   This property specifies the mode of the file transfer. Valid values are 0 for an ASCII file transfer, 1 for a binary file transfer, and 2 for a binary transfer that saves the file information in a file header.

UserPassword, type String, write access
   The string used for the user password when connecting to the host’s file transfer server program.

Method reference

Boolean Connect()
   This method attempts to connect to the host’s file transfer server program at the IP address specified by the HostAddress property. The Port property is used to identify the requested host program. Connect sets the ConnectStatus property and returns True if the connection request succeeded, else it returns False.

void Disconnect()
   This method disconnects from the host’s file transfer server program.

integer HostCommand( String CommandString )
   This method executes a MPE command or MPE command file. The CommandString parameter specifies the command or command file to be executed. A return of 0 indicates the command was executed sucessfully, while a return of 1 indicates that the command failed.

Boolean HostLogin()
   This method changes the host server login to that specified by the LoginUser, UserPassword, LoginGroup, GroupPassword, LoginAccount, AccountPassword, and JobName properties. A return of True indicates that the login was changed successfully.

void SaveConfig()
   This method saves the writeable session object properties to a file. This file can later be use to initialize a session object when created.

Boolean LoadConfig( String FileName )
   This method loads the session object properties from the named file. A return of True indicates the properties were loaded successfully.

Boolean SetSessionConfig()
   This method displays the “Session Configuration” dialog of the File Transfer Access Engine. This dialog allows the user to set the following properties: HostAddress, Port, LoginUser, UserPassword, LoginGroup, GroupPassword, LoginAccount, AccountPassword, and JobName. A return of True indicates the user clicked on OK to exit the dialog, else a return of False indicates the user clicked on Cancel to exit the dialog.

Boolean SetTransferConfig()
   This method displays the “File Transfer Configuration” dialog of the File Transfer Access Engine. This dialog allows the user to set default file transfer options. A return of True indicates the user clicked on OK to exit the dialog, else a return of False indicates the user clicked on Cancel to exit the dialog.

integer StartTransfer()
   This method initiates a file transfer. A return of 0 indicates the file transfer was successful, while a return of 1 indicates that the file transfer failed.

FTP Engine

The FTP Engine objects are used by the client program to communicate with a FTP server program on the host. This gives the client the ability to transfer files to/from any host that supports FTP. In order to access the FTP engine from a client program, the client program must create the Session object of the FTP Engine as follows:

Visual BASIC:

Dim FTPSession As Object … Set FTPSession = CreateObject(“MdmFTP.Session”)

Visual C++:

CreateDispatch( “MdmFTP.Session” );

When the client program wishes to stop using the FTP Engine, then it must delete the Session object as follows:

Visual BASIC:

Set FTPSession = Nothing

Visual C++:

ReleaseDispatch();

Session Object

Once the Session object has been created the client can access its properties and methods to access the host’s FTP server program. Typically the properties specifying the host’s IP address and login information are set, then the Connect method is called to connect the the host’s FTP server program.

Property reference

AccountPassword, type String, write access
   The string used for the account password when connecting to the host’s FTP server program. Some hosts require account information.

ConnectStatus, type Boolean, read access
   Contains True if the last connection attempt was successful, else False.

CtrlZIsEof, type Boolean, write access
   This property specifies whether the end-of-file of a PC file is marked with a CTRL-Z character or not. A value of True indicates that a CTRL-Z found in the file will be interpreted as the EOF on uploads, and that a CTRL-Z will be written at the end of the file on downloads. A value of False indicates that a CTRL-Z found in the file will be intepreted as normal data on uploads, and that a CTRL-Z will not be written at the end of the file on downloads. This property only applies to ASCII transfers. The default is False.

DirectoryList, type String, read access
   This property contains a list of subdirectories contained by the current host directory. It is updated after every successful call to the RefreshFileList method.

DisplayStats, type Boolean, write access
   This property specifies whether a dialog box showing the status of the transfer should be displayed during the file transfer. The default is False.

ErrorMessage, type String, read access
   Contains the last error message generated

ErrorNumber, type integer, read access
   Contains the last error number generated.

FileList, type String, read access
   This property contains a list of files contained by the current host directory. It is updated after every successful call to the RefreshFileList method.

FileTransferStatus, type integer, read access
This property indicates the status of an in-progress or completed file transfer. A value of 0 indicates that the last transfer was completed successfully.

HostAddress, type String, write access
The host name or IP address used when attempting to connect to the host.

HostType, type integer, write access
This property specifies the type of host connecting to. Valid types are:

1 – Unix 2 – IBM VM 3 – VMS/Multinet 4 – VMS/UCX 5 – FTP’s PCTCP 6 – CUTCP/NCSA 7 – NOS/KA9Q 8 – WinQVT/Net 9 – IBMPC TCP/IP 10 – CHAMELEON 11 – SuperTCP 12 – SI NT/FTPD 13 – IBM MVS 14 – Unisys 5000

LoginStatus, type Boolean, read access
Contains True if the login information supplied when connecting to the host’s FTP server program was valid, else False.

LoginUser, type String, write access
The string used for the user name when connecting to the host’s FTP server program.

SpacesPerTab, type integer, write access
This property sets the distance between tab stops and enables changing tab characters to spaces to fill to the next tab stop. It is used only on ASCII uploads. A value of 0 disables the replacement of tab characters. Valid values are between 0 and 9. The default is 0.

UserPassword, type String, write access
The string used for the user password when connecting to the host’s FTP server program.

Method reference

Boolean ChangeDirectory( String Directory )
This method attempts to change the current directory of the host’s FTP server program to the directory specified by the Directory parameter. A return of True indicates that the current directory was changed.

Boolean Connect()
This method attempts to connect to the host’s FTP server program at the host name or IP address specified by the HostAddress property. The LoginUser, UserPassword, and AccountPassword (optional) properties should be set before calling the Connect method. Connect sets the ConnectStatus property and returns True if the connection request succeeded, else it returns False.

String CurrentDirectory()
This method returns the name of the current directory of the host’s FTP server program.

Boolean DeleteFile( String FileName )
This method deletes the host file specified by the FileName parameter. A return of True indicates that the file was deleted.

void Disconnect()
This method disconnects from the host’s FTP server program.

Boolean Login()
This method changes the host server login to that specified by the LoginUser, UserPassword, and AccountPassword (optional) properties. A return of True indicates that the login was changed successfully.

Boolean RefreshFileList( String ListPath )
This method retrieves a list of all files and directories matching the ListPath parameter. The ListPath parameter may contain any valid path and/or file wildcard characters. The DirectoryList and FileList properties are updated upon successful completion of this method.

Boolean RenameFile( String OldName, String NewName )
This method renames the file specified by the OldName parameter to the name specified by the NewName parameter. A return of True indicated that the rename was successful.

integer RetrieveFile( String HostFileName, String LocalFileName, integer Type, integer ExistsAction )
This method transfers the file specified by the HostFileName parameter from the host to the file specified by the LocalFileName parameter on the PC. The Type parameter is either 0 for an ASCII transfer or 1 for a binary transfer. The ExistsAction parameter specifies what action to take if the PC file already exists. A value of 0 indicates that the transfer should be cancelled. A value of 1 indicates that the PC file should be deleted and the transfer should continue. A value of 2 indicates that the user should be prompted whether to delete the file or cancel the transfer. A value of 3 indicates that the PC file should be appended to. A return value of 0 indicates that the transfer was completed successfully.

Boolean SetSessionConfig()
This method displays the “Session Configuration” dialog of the FTP Engine. This dialog allows the user to set the following properties: HostAddress, HostType, LoginUser, UserPassword, and AccountPassword. A return of True indicates the user clicked on OK to exit the dialog, else a return of False indicates the user clicked on Cancel to exit the dialog.

Boolean SetTransferConfig()
This method displays the “File Transfer Configuration” dialog of the FTP Engine. This dialog allows the user to set default file transfer options. A return of True indicates the user clicked on OK to exit the dialog, else a return of False indicates the user clicked on Cancel to exit the dialog.

integer StoreFile( String LocalFileName, String HostFileName, integer Type, integer ExistsAction )
This method transfers the file specified by the LocalFileName parameter from the PC to the file specified by the HostFileName parameter on the host. The Type parameter is either 0 for an ASCII transfer or 1 for a binary transfer. The ExistsAction parameter specifies what action to take if the host file already exists. A value of 1 indicates that the host file should be deleted and the transfer should continue. A value of 3 indicates that the host file should be appended to. A return value of 0 indicates that the transfer was completed successfully.

Calling the OLE Automation Engines from Visual C++
Type libraries to describe the API for the File Transfer Engine and the FTP Engine are included in the installation directory. They are called “mdmft.tlb” and “mdmftp.tlb” respectively. They can be used with the Read Type Library option under the Ole Automation tab of the ClassWizard dialog box of Microsoft Visual C++. When a type libary is read this way a new class derived from COleDispatchDriver is created which will contain member functions to access the properties and methods of the requested Ole automation engine.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

code