Qtp-dt-parameter

提供:Dev Guides
移動先:案内検索

QTP-DTParameterオブジェクトのプロパティ

Method Name Description Syntax
Name Returns the name of the parameter in the run-time datatable. DTParameter.Name
RawValue Returns the raw value of the cell in the current row of the runtime datatable. DTParameter.RawValue
Value Retrieves or sets the value of the cell in the Active row of the parameter in the run-time datatable. DTParameter.Value
ValueByRow Retrieves the value of the cell in the specified row of the parameter in the run-time datatable. DTParameter.ValueByRow (RowNum)

次のDataTableを考慮してください-

RowCountとColumn Countを取得

Val = DataTable.GetSheet("Global").GetParameter("Principal").ValueByRow(2)
print Val ' Val Displays 2556

DataTable.SetCurrentRow(1)
Val1 = DataTable.GetSheet("Global").GetParameter("Principal").Value
print Val1 ' Val1 displays 232