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




Home
Suggested Reading


Previous page Back to top Next page

© 2000-2010 Rey Nuñez All rights reserved.

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

You can help support asp.net.ph