action_="files"

<do action_="files"> retrieves a list of files in a valid FTP directory. (Available as of version 10.25)

Syntax

<dynamic tv="">
    <do action_="files" 
     tablevalue_="@tv"/>
</dynamic>

Attributes for action_="files"

tablevalue_
The results of the <do> clause are stored as a table value in the dynamic variable associated with this attribute.

The table contains one row for each file in the user's FTP directory.

The variable associated with this attribute can be indexed using the following syntax:
  • @foo.bar provides a list consisting of the values in the column bar
  • @foo.17 provides a dictionary consisting of the row 17
  • @foo._cols provides a list of column names
  • @foo._rows provides the number of rows
Note: The user must be authorized to use FTP and have a valid FTP directory.

Example

<dynamic my_ftp_files="">
  <do action_="files" tablevalue_="@my_ftp_files"/>
  <layout arrange_="v">
    <widget class_="text" text_="Columns: {@my_ftp_files._cols}"/>
    <widget class_="text" text_="Rows: {@my_ftp_files._rows}"/>
    <widget class_="text" text_="Path: {@my_ftp_files.path}"/>
    <widget class_="nest">
      <dynamic>
        <layout arrange_="v">
          <foreach column="{@my_ftp_files._cols}">
            <layout arrange_="h">
              <widget class_="text" text_="{@column}:" width_="100"/>
              <widget class_="text" text_="{@my_ftp_files.{@column}}"/>
            </layout>
          </foreach>
        </layout>
      </dynamic>
    </widget>
  </layout>
</dynamic>