DataProviderNameConverter.GetStandardValues(ITypeDescriptorContext) 方法

定义

返回 .NET Framework (ADO.NET) 提供程序名称的可用 ActiveX® 数据对象 (ADO) 的列表。

public:
 override System::ComponentModel::TypeConverter::StandardValuesCollection ^ GetStandardValues(System::ComponentModel::ITypeDescriptorContext ^ context);
public override System.ComponentModel.TypeConverter.StandardValuesCollection GetStandardValues (System.ComponentModel.ITypeDescriptorContext context);
override this.GetStandardValues : System.ComponentModel.ITypeDescriptorContext -> System.ComponentModel.TypeConverter.StandardValuesCollection
Public Overrides Function GetStandardValues (context As ITypeDescriptorContext) As TypeConverter.StandardValuesCollection

参数

context
ITypeDescriptorContext

一个实现 ITypeDescriptorContext 的对象,该对象将有关上下文的信息提供给类型转换器,以便类型转换器可以执行转换。

返回

TypeConverter.StandardValuesCollection

TypeConverter.StandardValuesCollection,它包含可用 ADO.NET 提供程序的名称。

注解

GetStandardValues方法使用 GetFactoryClasses 方法返回 DataTable 一个对象,该对象包含 ADO.NET 名称。 它将此 DataTable 转换为字符串数组,然后将此数组转换为 TypeConverter.StandardValuesCollection 对象。

context参数不由 使用 GetStandardValues

适用于

另请参阅