SEDRIS Reference Manual
APPENDIX A - Transmittal Access Level 0 API
Functions
SE OpenTransmittalByFile
extern SE_Return_Code
SE_OpenTransmittalByFile
(
constchar file_location[], (notes)
SE_Encoding encoding, (notes)
SE_Access_Mode access_mode, (notes)
SE_Transmittal *transmittal_out_ptr (notes)
);

Definition

Opens a SEDRIS transmittal for access, based on the mode specified. This function specifies the SEDRIS transmittal to be opened using the file name of the file / format containing the SEDRIS transmittal and its objects.


Returns

SE_RET_CODE_SUCCESS and the opened tranmittal is returned.
SE_RET_CODE_FAILUREand the status code is set appropriately if the call failed.

Status Codes

SE_Status_Code(s) when SE_RET_CODE_SUCCESS is returned:

SE_STAT_CODE_SUCCESS set if valid parameters were passed in and the name was the name of a valid file that this API was able to open as a SEDRIS transmittal.

SE_Status_Code(s) when SE_RET_CODE_FAILURE is returned:

SE_STAT_CODE_TRANSMITTAL_INACCESSIBLE set if the file_location was not accessible by the API. This could occur if
  1. the file was opened for read-only or update and the file did not exist, or
  2. the file location specified a non-local file and the API had no transport mechanism for accessing the remote file.
SE_STAT_CODE_INVALID_ACCESS_MODE set if the file_location was found, but the security permissions of the underlying system (OS / filesystem) prohibited access to the file in the mode specified. This could occur if the access mode specified was create or update and the file was marked read-only, or if no access was permitted for the account running the application. This condition could also occur if create or update mode was requested and the API implementation encoding did not support the write capability.
SE_STAT_CODE_UNSUPPORTED_ENCODING set if the encoding parameter or the default file extension specified a format that is not supported by the implementation(s) encoding of the SEDRIS API linked to the application.
SE_STAT_CODE_INACTIONABLE_FAILURE set if the call fails for any other reason.


Parameters Notes


file_location

 the file location of the SEDRIS transmittal to be opened.

encoding

 the API implementation encoding
    to use when opening this file.  If the specified API can't open the
    given file location then the API will return a status code indicating
    why it could not be opened.  If encoding is NULL, then
    the API will try to open the given SEDRIS transmittal based on the
    extension of the file location.

    See also SE_GetEncoding().

access_mode

  the mode (read-only, create, update, etc.) that the
  SEDRIS transmittal should be opened in.

transmittal_out_ptr

  a pointer to the SE_Transmittal from the user.
  The *transmittal_out_ptr value will be initialized by this function.


Prev: SE_ObjectsAreSame. Next: SE_OpenTransmittalByName. Up:Index.

Last updated: July 16, 2004 Copyright © 2004 SEDRIS