IDataParameter.SourceColumn Property

Definition

Gets or sets the name of the source column that is mapped to the DataSet and used for loading or returning the Value.

public:
 property System::String ^ SourceColumn { System::String ^ get(); void set(System::String ^ value); };
public string SourceColumn { get; set; }
member this.SourceColumn : string with get, set
Public Property SourceColumn As String

Property Value

The name of the source column that is mapped to the DataSet. The default is an empty string.

Examples

The following example creates an instance of the implementing class, SqlParameter, and sets some of its properties.

public void CreateSqlParameter()
{
    SqlParameter parameter = new SqlParameter(
        "@Description", SqlDbType.VarChar);
    parameter.IsNullable = true;
    parameter.Direction = ParameterDirection.Output;
    parameter.SourceColumn = "Description";
}
Public Sub CreateSqlParameter()
    Dim parameter As New SqlParameter( _
        "@Description", SqlDbType.VarChar)
    parameter.IsNullable = True
    parameter.Direction = ParameterDirection.Output
    parameter.SourceColumn = "Description"
End Sub

Remarks

The link between the value of the IDataParameter and the DataTable may be bidirectional depending on the value of the Direction property.

Applies to