asp.net.ph

OleDbParameter Constructor ( String, Object )

System.Data.OleDb Namespace   OleDbParameter Class


Initializes a new instance of the OleDbParameter class with the parameter name and value.

[ VB ]
Overloads Public Sub New ( _
   ByVal name As String, _
   ByVal value As Object _
)

[ C# ]
public OleDbParameter (
   string name,
   object value
);

[ C++ ]
public: OleDbParameter (
   String* name,
   Object value
);

[ JScript ]
public function OleDbParameter (
   name : String,
   value : Object
);

Parameters

name
The name of the parameter to map.
value
The value of the new OleDbParameter object.

Remarks

When you specify an Object in the value parameter, the OleDbType is inferred from the .NET Framework type of the Object.

Example

The following example initializes an OleDbParameter and sets some of its properties.

public void CreateOleDbParameter ( ) {
   OleDbParameter myParam = new OleDbParameter ( "Category", "Beverages" );
   myParam.Direction = ParameterDirection.Output;
}
  C# VB

See Also

OleDbParameter Members   OleDbParameter Constructor Overload List Skip Navigation Links




Previous page Back to top Next page

Check out related books at Amazon

© 2025 Reynald Nuñez and asp.net.ph. All rights reserved.

If you have any question, comment or suggestion
about this site, please send us a note