一种方法是编写一个脚本,将文本分成几行(使用
GetValue()
),然后用分号分隔每一行(
Substitute( $line, ";", "¶" )
获取值()
我会这样写:
Go to Layout( My Table )
Go to Record/Request/Page[ First ]
# Loop over records
Loop
Set Variable[ $line, 1 ]
# Loop over lines
Loop
Exit Loop If[ ValueCount( My Table::My Field ) < $line ]
#
# Get line values
Set Variable[ $fields,
Substitute( GetValue( My Table::My Field, $line ), ";", "¶" ) ]
# ...
Go to Layout( My Target Table )
New Record/Request
Set Field[ My Target Table::Foo, GetValue( $fields, 1 ) ]
Set Field[ My Target Table::Foo, GetValue( $fields, 2 ) ]
Go to Layout( My Table )
#
Set Variable[ $line, $line + 1 ]
End Loop
Go to Record/Request/Page[ Next, Exit After Last ]
End Loop
Go to Layout( original layout )