ArcGIS Explorer Component Help |
Geodatabase..::.Type Property |
Geodatabase Class Example See Also |
Gets the type of geodatabase, which can be either a file geodatabase or an ArcSDE geodatabase.
Namespace:
ESRI.ArcGISExplorer.DataAssembly: ESRI.ArcGISExplorer (in ESRI.ArcGISExplorer.dll) Version: 2.0.0.1500 (2.0.0.1500)
Syntax
C# |
---|
public GeodatabaseType Type { get; set; } |
Visual Basic (Declaration) |
---|
Public Property Type As GeodatabaseType |
Field Value
One of the GeodatabaseType values indicating the type of the geodatabase.Examples
The code below creates a new Geodatabase object and opens a connection to a file geodatabase then returns
some information about it including the type of geodatabase.
CopyC#
//Connect to a file geodatabase Geodatabase fileGdb = new Geodatabase(@"C:\Data\Scotland.gdb"); //Print the type of geodatabase System.Diagnostics.Debug.Print(fileGdb.Type.ToString()); //prints "File" //Print the geodatabase path System.Diagnostics.Debug.Print(fileGdb.Path); //prints "C:\Data\Scotland.gdb" //Print the short name for the geodatabase System.Diagnostics.Debug.Print(fileGdb.Name); //prints "Scotland.gdb" //Print the short name for the geodatabase System.Diagnostics.Debug.Print(fileGdb.ShortName); //prints "Scotland"
CopyVB.NET
'Connect to a file geodatabase Dim fileGdb As Geodatabase = New Geodatabase("C:\Data\Scotland.gdb") 'Print the type of geodatabase System.Diagnostics.Debug.Print(fileGdb.Type) 'prints "File" 'Print the geodatabase path System.Diagnostics.Debug.Print(fileGdb.Path) 'prints "C:\Data\Scotland.gdb" 'Print the short name for the geodatabase System.Diagnostics.Debug.Print(fileGdb.Name) 'prints "Scotland.gdb" 'Print the short name for the geodatabase System.Diagnostics.Debug.Print(fileGdb.ShortName) 'prints "Scotland"