DataSet.Prefix Propiedad
Importante
Parte de la información hace referencia a la versión preliminar del producto, que puede haberse modificado sustancialmente antes de lanzar la versión definitiva. Microsoft no otorga ninguna garantía, explícita o implícita, con respecto a la información proporcionada aquí.
Obtiene o establece un prefijo XML que crea alias para el espacio de nombres del objeto DataSet.
public:
property System::String ^ Prefix { System::String ^ get(); void set(System::String ^ value); };
public string Prefix { get; set; }
[System.Data.DataSysDescription("DataSetPrefixDescr")]
public string Prefix { get; set; }
member this.Prefix : string with get, set
[<System.Data.DataSysDescription("DataSetPrefixDescr")>]
member this.Prefix : string with get, set
Public Property Prefix As String
Prefijo XML para el espacio de nombres de DataSet.
- Atributos
En el ejemplo siguiente se establece antes Prefix de llamar al ReadXml método .
private void ReadData(DataSet thisDataSet)
{
thisDataSet.Namespace = "CorporationA";
thisDataSet.Prefix = "DivisionA";
// Read schema and data.
string fileName = "CorporationA_Schema.xml";
thisDataSet.ReadXmlSchema(fileName);
fileName = "DivisionA_Report.xml";
thisDataSet.ReadXml(fileName);
}
Private Sub ReadData(thisDataSet As DataSet)
thisDataSet.Namespace = "CorporationA"
thisDataSet.Prefix = "DivisionA"
' Read schema and data.
Dim fileName As String = "CorporationA_Schema.xml"
thisDataSet.ReadXmlSchema(fileName)
fileName = "DivisionA_Report.xml"
thisDataSet.ReadXml(fileName)
End Sub
La Prefix propiedad se usa a lo largo de un documento XML para identificar los elementos que pertenecen al espacio de nombres del DataSet objeto (según lo establecido por la Namespace propiedad ).
Comentarios de .NET
.NET es un proyecto de código abierto. Seleccione un vínculo para proporcionar comentarios: