Share via


WebTest.AddDataSourceBinding Method

Defines a binding relationship and adds it to the data source binding collection for the Web performance test.

Namespace:  Microsoft.VisualStudio.TestTools.WebTesting
Assembly:  Microsoft.VisualStudio.QualityTools.WebTestFramework (in Microsoft.VisualStudio.QualityTools.WebTestFramework.dll)

Syntax

'Declaration
Public Overridable Sub AddDataSourceBinding ( _
    dataSourceName As String, _
    tableName As String, _
    columnName As String, _
    contextName As String _
)
public virtual void AddDataSourceBinding(
    string dataSourceName,
    string tableName,
    string columnName,
    string contextName
)
public:
virtual void AddDataSourceBinding(
    String^ dataSourceName, 
    String^ tableName, 
    String^ columnName, 
    String^ contextName
)
abstract AddDataSourceBinding : 
        dataSourceName:string * 
        tableName:string * 
        columnName:string * 
        contextName:string -> unit 
override AddDataSourceBinding : 
        dataSourceName:string * 
        tableName:string * 
        columnName:string * 
        contextName:string -> unit 
public function AddDataSourceBinding(
    dataSourceName : String, 
    tableName : String, 
    columnName : String, 
    contextName : String
)

Parameters

  • dataSourceName
    Type: System.String
    The name of the data source.
  • tableName
    Type: System.String
    The name of a table in the data source.
  • columnName
    Type: System.String
    The name of a column in the table to that is used for binding.
  • contextName
    Type: System.String
    The variable name that represents the binding.

Exceptions

Exception Condition
WebTestException

dataSourceName does not represent a data source that is found in the internal Web performance test data source collection.

.NET Framework Security

See Also

Reference

WebTest Class

Microsoft.VisualStudio.TestTools.WebTesting Namespace