Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Group

IO

Utilities

Description

Export a list of IOs configurations from a project into a file (*.rios)

IMPORTANT:
Note

Projects whose IOs are exported must be closed.

Required Control

None

Usage

RtlabApi.ExportIOsConfiguration(project_path_src, dir_path_to_export_ios='', filename='', io_list_name_to_export=[])

Input

Export IOs from projet
  • project_path_src

into a file located by 'dir_path_to_export_ios' with the name defined by 'filename'.

IMPORTANT: Projects whose IOs are exported must be closed.

Note
  • :

We advise specifying the path with r'<path>' format instead of "<path>" to avoid interpretation of the escape character (\t, \n...)

Parameters

project_path_src {str} --
  • Directory path to the project whose IOs are to be exported.
    dir_path_to_export_ios

{str} --
  • : Path where the file containing

the
  • exported IOs is stored

  • filename

{str} --
  • : file name containing

the
  • exported IOs

  • io_list_name_to_export {str/list/empty}

-- to be exported.
If empty or omitted, all IOs from project 'project_path_src' will be exported
  • : Given IO or list of IOs to be exported.
    If empty or omitted, all IOs from project 'project_path_src' will be exported.

Returns

  • abs_file_path_to_ios_exported {str} -- absolute file path to the file containing exported ios
Input
  • project_path_src {str} -- Directory path to the project whose IOs are to be exported.
    dir_path_to_export_ios {str} -- Path where the file containing exported IOs is stored
  • filename {str} -- file name containing exported IOs
  • io_list_name_to_export {str/list/empty} -- Given IO or list of IOs
    Info

    Note: We recommend the r'<path>' syntax instead of "<path>" to avoid interpretation of the escape character (\t, \n...).

    Output

    • abs_file_path_to_ios_exported

    {str} --
    • : absolute file path to the file containing exported

    ios
    • IOs

    Exception

    Method return 'None' if an error occurred

    Examples

    >>> r.ExportIOsConfiguration(r'C:\__WORKSPACE__\tmp\opcua', r'C:\\temp\\rios\\')

    'C:\\temp\\rios\\opcua.rios'

    Related Items

    ImportIOsConfiguration, GetIOsConfiguration

    Modules

    import RtlabApi