(2012-03-29)

This commit is contained in:
2012-03-29 00:00:00 +02:00
parent a2717a0661
commit f7ebb8c065
35 changed files with 122 additions and 2054 deletions

View File

@@ -0,0 +1,7 @@
REM Tool from: http://www.programmersheaven.com/download/41236/download.aspx
for /f "tokens=*" %%a IN ('dir /b /s *.sln') do ssr.exe 0 "Format Version 10.00" "Format Version 11.00" %%a
for /f "tokens=*" %%a IN ('dir /b /s *.sln') do ssr.exe 0 "# Visual Studio 2008" "# Visual Studio 2010" %%a
for /f "tokens=*" %%a IN ('dir /b /s *.csproj') do ssr.exe 0 "ToolsVersion=''3.5''" "ToolsVersion=''4.0''" %%a
for /f "tokens=*" %%a IN ('dir /b /s *.csproj') do ssr.exe 0 "v9.0" "v10.0" %%a

View File

@@ -0,0 +1,7 @@
REM SSR.EXE tool from: http://www.programmersheaven.com/download/41236/download.aspx
for /f "tokens=*" %%a IN ('dir /b /s *.sln') do ssr.exe 0 "Format Version 11.00" "Format Version 10.00" %%a
for /f "tokens=*" %%a IN ('dir /b /s *.sln') do ssr.exe 0 "# Visual Studio 2010" "# Visual Studio 2008" %%a
for /f "tokens=*" %%a IN ('dir /b /s *.csproj') do ssr.exe 0 "ToolsVersion=''4.0''" "ToolsVersion=''3.5''" %%a
for /f "tokens=*" %%a IN ('dir /b /s *.csproj') do ssr.exe 0 "v10.0" "v9.0" %%a

View File

@@ -1,20 +0,0 @@
Microsoft Visual Studio Solution File, Format Version 10.00
# Visual Studio 2008
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ServerExplorer", "ServerExplorer\ServerExplorer.csproj", "{79531B74-3062-4A71-9953-5702BEBDEC0E}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{79531B74-3062-4A71-9953-5702BEBDEC0E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{79531B74-3062-4A71-9953-5702BEBDEC0E}.Debug|Any CPU.Build.0 = Debug|Any CPU
{79531B74-3062-4A71-9953-5702BEBDEC0E}.Release|Any CPU.ActiveCfg = Release|Any CPU
{79531B74-3062-4A71-9953-5702BEBDEC0E}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
EndGlobal

View File

@@ -1,21 +0,0 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Windows.Forms;
namespace ServerExplorer
{
static class Program
{
/// <summary>
/// The main entry point for the application.
/// </summary>
[STAThread]
static void Main()
{
Application.EnableVisualStyles();
Application.SetCompatibleTextRenderingDefault(false);
Application.Run(new frmPrincipal());
}
}
}

View File

@@ -1,36 +0,0 @@
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("ServerExplorer")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("cyc")]
[assembly: AssemblyProduct("ServerExplorer")]
[assembly: AssemblyCopyright("Copyright © cyc 2012")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]
// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("31f76805-336c-471c-8af2-a4c1364e97b9")]
// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]

View File

@@ -1,71 +0,0 @@
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:2.0.50727.3082
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
namespace ServerExplorer.Properties
{
/// <summary>
/// A strongly-typed resource class, for looking up localized strings, etc.
/// </summary>
// This class was auto-generated by the StronglyTypedResourceBuilder
// class via a tool like ResGen or Visual Studio.
// To add or remove a member, edit your .ResX file then rerun ResGen
// with the /str option, or rebuild your VS project.
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "2.0.0.0")]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
internal class Resources
{
private static global::System.Resources.ResourceManager resourceMan;
private static global::System.Globalization.CultureInfo resourceCulture;
[global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
internal Resources()
{
}
/// <summary>
/// Returns the cached ResourceManager instance used by this class.
/// </summary>
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
internal static global::System.Resources.ResourceManager ResourceManager
{
get
{
if ((resourceMan == null))
{
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("ServerExplorer.Properties.Resources", typeof(Resources).Assembly);
resourceMan = temp;
}
return resourceMan;
}
}
/// <summary>
/// Overrides the current thread's CurrentUICulture property for all
/// resource lookups using this strongly typed resource class.
/// </summary>
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
internal static global::System.Globalization.CultureInfo Culture
{
get
{
return resourceCulture;
}
set
{
resourceCulture = value;
}
}
}
}

View File

@@ -1,117 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

View File

@@ -1,30 +0,0 @@
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:2.0.50727.3082
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
namespace ServerExplorer.Properties
{
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "9.0.0.0")]
internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase
{
private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
public static Settings Default
{
get
{
return defaultInstance;
}
}
}
}

View File

@@ -1,7 +0,0 @@
<?xml version='1.0' encoding='utf-8'?>
<SettingsFile xmlns="http://schemas.microsoft.com/VisualStudio/2004/01/settings" CurrentProfile="(Default)">
<Profiles>
<Profile Name="(Default)" />
</Profiles>
<Settings />
</SettingsFile>

View File

@@ -1,107 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="3.5" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProductVersion>9.0.30729</ProductVersion>
<SchemaVersion>2.0</SchemaVersion>
<ProjectGuid>{79531B74-3062-4A71-9953-5702BEBDEC0E}</ProjectGuid>
<OutputType>WinExe</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>ServerExplorer</RootNamespace>
<AssemblyName>ServerExplorer</AssemblyName>
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="System" />
<Reference Include="System.Core">
<RequiredTargetFramework>3.5</RequiredTargetFramework>
</Reference>
<Reference Include="System.Xml.Linq">
<RequiredTargetFramework>3.5</RequiredTargetFramework>
</Reference>
<Reference Include="System.Data.DataSetExtensions">
<RequiredTargetFramework>3.5</RequiredTargetFramework>
</Reference>
<Reference Include="System.Data" />
<Reference Include="System.Deployment" />
<Reference Include="System.Drawing" />
<Reference Include="System.Windows.Forms" />
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="frmBaseDatos.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="frmBaseDatos.Designer.cs">
<DependentUpon>frmBaseDatos.cs</DependentUpon>
</Compile>
<Compile Include="frmPrincipal.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="frmPrincipal.Designer.cs">
<DependentUpon>frmPrincipal.cs</DependentUpon>
</Compile>
<Compile Include="frmServidores.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="frmServidores.Designer.cs">
<DependentUpon>frmServidores.cs</DependentUpon>
</Compile>
<Compile Include="Program.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<EmbeddedResource Include="frmBaseDatos.resx">
<DependentUpon>frmBaseDatos.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="frmPrincipal.resx">
<DependentUpon>frmPrincipal.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="frmServidores.resx">
<DependentUpon>frmServidores.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="Properties\Resources.resx">
<Generator>ResXFileCodeGenerator</Generator>
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
<SubType>Designer</SubType>
</EmbeddedResource>
<Compile Include="Properties\Resources.Designer.cs">
<AutoGen>True</AutoGen>
<DependentUpon>Resources.resx</DependentUpon>
</Compile>
<None Include="Properties\Settings.settings">
<Generator>SettingsSingleFileGenerator</Generator>
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
</None>
<Compile Include="Properties\Settings.Designer.cs">
<AutoGen>True</AutoGen>
<DependentUpon>Settings.settings</DependentUpon>
<DesignTimeSharedInput>True</DesignTimeSharedInput>
</Compile>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>

View File

@@ -1,182 +0,0 @@
namespace ServerExplorer
{
partial class frmBaseDatos
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
this.txtConString = new System.Windows.Forms.TextBox();
this.lblConString = new System.Windows.Forms.Label();
this.btnCopiarConString = new System.Windows.Forms.Button();
this.lsvTablas = new System.Windows.Forms.ListView();
this.colNombreTabla = new System.Windows.Forms.ColumnHeader();
this.colEsquema = new System.Windows.Forms.ColumnHeader();
this.colTipo = new System.Windows.Forms.ColumnHeader();
this.lsvColumnas = new System.Windows.Forms.ListView();
this.colNombreColumna = new System.Windows.Forms.ColumnHeader();
this.colTipoDatos = new System.Windows.Forms.ColumnHeader();
this.colTamanho = new System.Windows.Forms.ColumnHeader();
this.dataGridView1 = new System.Windows.Forms.DataGridView();
((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).BeginInit();
this.SuspendLayout();
//
// txtConString
//
this.txtConString.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.txtConString.Location = new System.Drawing.Point(123, 12);
this.txtConString.Name = "txtConString";
this.txtConString.ReadOnly = true;
this.txtConString.Size = new System.Drawing.Size(472, 20);
this.txtConString.TabIndex = 0;
//
// lblConString
//
this.lblConString.AutoSize = true;
this.lblConString.Location = new System.Drawing.Point(12, 15);
this.lblConString.Name = "lblConString";
this.lblConString.Size = new System.Drawing.Size(105, 13);
this.lblConString.TabIndex = 1;
this.lblConString.Text = "Cadena de conexion";
//
// btnCopiarConString
//
this.btnCopiarConString.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.btnCopiarConString.Location = new System.Drawing.Point(601, 10);
this.btnCopiarConString.Name = "btnCopiarConString";
this.btnCopiarConString.Size = new System.Drawing.Size(52, 23);
this.btnCopiarConString.TabIndex = 3;
this.btnCopiarConString.Text = "Copiar";
this.btnCopiarConString.UseVisualStyleBackColor = true;
this.btnCopiarConString.Click += new System.EventHandler(this.btnCopiarConString_Click);
//
// lsvTablas
//
this.lsvTablas.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)));
this.lsvTablas.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
this.colNombreTabla,
this.colEsquema,
this.colTipo});
this.lsvTablas.Location = new System.Drawing.Point(12, 38);
this.lsvTablas.Name = "lsvTablas";
this.lsvTablas.Size = new System.Drawing.Size(326, 426);
this.lsvTablas.TabIndex = 4;
this.lsvTablas.UseCompatibleStateImageBehavior = false;
this.lsvTablas.View = System.Windows.Forms.View.Details;
this.lsvTablas.SelectedIndexChanged += new System.EventHandler(this.lsvTablas_SelectedIndexChanged);
//
// colNombreTabla
//
this.colNombreTabla.Text = "Tabla";
this.colNombreTabla.Width = 169;
//
// colEsquema
//
this.colEsquema.Text = "Esquema";
//
// colTipo
//
this.colTipo.Text = "Tipo";
this.colTipo.Width = 71;
//
// lsvColumnas
//
this.lsvColumnas.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.lsvColumnas.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
this.colNombreColumna,
this.colTipoDatos,
this.colTamanho});
this.lsvColumnas.Location = new System.Drawing.Point(344, 38);
this.lsvColumnas.Name = "lsvColumnas";
this.lsvColumnas.Size = new System.Drawing.Size(309, 262);
this.lsvColumnas.TabIndex = 6;
this.lsvColumnas.UseCompatibleStateImageBehavior = false;
this.lsvColumnas.View = System.Windows.Forms.View.Details;
//
// colNombreColumna
//
this.colNombreColumna.Text = "Columna";
this.colNombreColumna.Width = 139;
//
// colTipoDatos
//
this.colTipoDatos.Text = "Tipo de Datos";
this.colTipoDatos.Width = 92;
//
// colTamanho
//
this.colTamanho.Text = "Tamaño";
//
// dataGridView1
//
this.dataGridView1.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.dataGridView1.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.dataGridView1.Location = new System.Drawing.Point(344, 306);
this.dataGridView1.Name = "dataGridView1";
this.dataGridView1.Size = new System.Drawing.Size(309, 158);
this.dataGridView1.TabIndex = 8;
//
// frmBaseDatos
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(665, 476);
this.Controls.Add(this.dataGridView1);
this.Controls.Add(this.lsvColumnas);
this.Controls.Add(this.lsvTablas);
this.Controls.Add(this.btnCopiarConString);
this.Controls.Add(this.lblConString);
this.Controls.Add(this.txtConString);
this.Name = "frmBaseDatos";
this.Text = "Base de Datos";
this.Load += new System.EventHandler(this.frmBaseDatos_Load);
((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).EndInit();
this.ResumeLayout(false);
this.PerformLayout();
}
#endregion
private System.Windows.Forms.TextBox txtConString;
private System.Windows.Forms.Label lblConString;
private System.Windows.Forms.Button btnCopiarConString;
private System.Windows.Forms.ListView lsvTablas;
private System.Windows.Forms.ColumnHeader colNombreTabla;
private System.Windows.Forms.ColumnHeader colEsquema;
private System.Windows.Forms.ColumnHeader colTipo;
private System.Windows.Forms.ListView lsvColumnas;
private System.Windows.Forms.ColumnHeader colNombreColumna;
private System.Windows.Forms.ColumnHeader colTipoDatos;
private System.Windows.Forms.ColumnHeader colTamanho;
private System.Windows.Forms.DataGridView dataGridView1;
}
}

View File

@@ -1,94 +0,0 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using System.Data.Sql;
using System.Data.SqlClient;
namespace ServerExplorer
{
public partial class frmBaseDatos : Form
{
SqlConnection cnx;
public frmBaseDatos(String ConString)
{
InitializeComponent();
// Establecer conexion
txtConString.Text = ConString;
cnx = new SqlConnection(ConString);
}
private void frmBaseDatos_Load(object sender, EventArgs e)
{
// Obtener lista de tablas
cnx.Open();
DataTable dt = cnx.GetSchema("Tables");
cnx.Close();
// Mostrar todas las tablas
lsvTablas.Items.Clear();
foreach (DataRow dr in dt.Rows)
{
ListViewItem item = lsvTablas.Items.Add((String)dr["TABLE_NAME"]);
item.SubItems.Add((String)dr["TABLE_SCHEMA"]);
item.SubItems.Add((String)dr["TABLE_TYPE"]);
}
}
private void btnCopiarConString_Click(object sender, EventArgs e)
{
// Copiar la cadena de conexion al portapapeles
System.Windows.Forms.Clipboard.SetText(txtConString.Text);
}
private void lsvTablas_SelectedIndexChanged(object sender, EventArgs e)
{
if (lsvTablas.SelectedItems.Count == 1)
{
DataTable dt;
// Determinar tabla seleccionada
ListViewItem item = lsvTablas.SelectedItems[0];
// Obtener las columnas de la tabla
String[] restr_columna = { null, null, item.SubItems[0].Text, null };
// NOTA: Catalog, Owner, Table, TableType
cnx.Open();
dt = cnx.GetSchema("Columns", restr_columna);
cnx.Close();
// Mostrar "columnas" de las tablas
lsvColumnas.Items.Clear();
foreach (DataRow dr in dt.Rows)
{
ListViewItem subitem = lsvColumnas.Items.Add((String)dr["COLUMN_NAME"]);
subitem.SubItems.Add((String)dr["DATA_TYPE"]);
if (dr["CHARACTER_MAXIMUM_LENGTH"] != DBNull.Value)
{
subitem.SubItems.Add(String.Format("{0}",dr["CHARACTER_MAXIMUM_LENGTH"]));
}
}
// Obtener las restricciones de la tabla
cnx.Open();
dt = cnx.GetSchema("Restrictions");
dt = cnx.GetSchema("ForeignKeys");
//dt = cnx.GetSchema("Indexes");
//dt = cnx.GetSchema("IndexColumns");
//dt = cnx.GetSchema("Constraint");
cnx.Close();
// Mostrar las columnas de la tabla restricciones
dataGridView1.DataSource = dt;
}
}
}
}

View File

@@ -1,120 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

View File

@@ -1,114 +0,0 @@
namespace ServerExplorer
{
partial class frmPrincipal
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
this.menuStrip1 = new System.Windows.Forms.MenuStrip();
this.servidorToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.meiBuscarServidor = new System.Windows.Forms.ToolStripMenuItem();
this.baseDeDatosToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.meiConectarA = new System.Windows.Forms.ToolStripMenuItem();
this.meiConectarPRUEBAS = new System.Windows.Forms.ToolStripMenuItem();
this.menuStrip1.SuspendLayout();
this.SuspendLayout();
//
// menuStrip1
//
this.menuStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.servidorToolStripMenuItem,
this.baseDeDatosToolStripMenuItem});
this.menuStrip1.Location = new System.Drawing.Point(0, 0);
this.menuStrip1.Name = "menuStrip1";
this.menuStrip1.Size = new System.Drawing.Size(800, 24);
this.menuStrip1.TabIndex = 4;
this.menuStrip1.Text = "menuPrincipal";
//
// servidorToolStripMenuItem
//
this.servidorToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.meiBuscarServidor});
this.servidorToolStripMenuItem.Name = "servidorToolStripMenuItem";
this.servidorToolStripMenuItem.Size = new System.Drawing.Size(59, 20);
this.servidorToolStripMenuItem.Text = "Servidor";
//
// meiBuscarServidor
//
this.meiBuscarServidor.Name = "meiBuscarServidor";
this.meiBuscarServidor.Size = new System.Drawing.Size(160, 22);
this.meiBuscarServidor.Text = "Buscar Servidor";
this.meiBuscarServidor.Click += new System.EventHandler(this.meiBuscarServidor_Click);
//
// baseDeDatosToolStripMenuItem
//
this.baseDeDatosToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.meiConectarA,
this.meiConectarPRUEBAS});
this.baseDeDatosToolStripMenuItem.Name = "baseDeDatosToolStripMenuItem";
this.baseDeDatosToolStripMenuItem.Size = new System.Drawing.Size(88, 20);
this.baseDeDatosToolStripMenuItem.Text = "Base de Datos";
//
// meiConectarA
//
this.meiConectarA.Name = "meiConectarA";
this.meiConectarA.Size = new System.Drawing.Size(186, 22);
this.meiConectarA.Text = "Conectar a...";
//
// meiConectarPRUEBAS
//
this.meiConectarPRUEBAS.Name = "meiConectarPRUEBAS";
this.meiConectarPRUEBAS.Size = new System.Drawing.Size(186, 22);
this.meiConectarPRUEBAS.Text = "Conectar a PRUEBAS";
this.meiConectarPRUEBAS.Click += new System.EventHandler(this.meiConectarPRUEBAS_Click);
//
// frmPrincipal
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(800, 601);
this.Controls.Add(this.menuStrip1);
this.IsMdiContainer = true;
this.MainMenuStrip = this.menuStrip1;
this.Name = "frmPrincipal";
this.Text = "Explorador de Servidores";
this.menuStrip1.ResumeLayout(false);
this.menuStrip1.PerformLayout();
this.ResumeLayout(false);
this.PerformLayout();
}
#endregion
private System.Windows.Forms.MenuStrip menuStrip1;
private System.Windows.Forms.ToolStripMenuItem servidorToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem meiBuscarServidor;
private System.Windows.Forms.ToolStripMenuItem baseDeDatosToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem meiConectarA;
private System.Windows.Forms.ToolStripMenuItem meiConectarPRUEBAS;
}
}

View File

@@ -1,33 +0,0 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace ServerExplorer
{
public partial class frmPrincipal : Form
{
public frmPrincipal()
{
InitializeComponent();
}
private void meiConectarPRUEBAS_Click(object sender, EventArgs e)
{
frmBaseDatos frm = new frmBaseDatos("Data Source=SSSRV3;Initial Catalog=PRUEBAS;User ID=sa;Password=SLsssrv3");
frm.MdiParent = this;
frm.Show();
}
private void meiBuscarServidor_Click(object sender, EventArgs e)
{
frmServidores frm = new frmServidores();
frm.MdiParent = this;
frm.Show();
}
}
}

View File

@@ -1,123 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="menuStrip1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
</root>

View File

@@ -1,216 +0,0 @@
namespace ServerExplorer
{
partial class frmServidores
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
this.lsvServidores = new System.Windows.Forms.ListView();
this.btnListarServidores = new System.Windows.Forms.Button();
this.colNombreServidor = new System.Windows.Forms.ColumnHeader();
this.colInstancia = new System.Windows.Forms.ColumnHeader();
this.colVersion = new System.Windows.Forms.ColumnHeader();
this.lblServidor = new System.Windows.Forms.Label();
this.txtServidor = new System.Windows.Forms.TextBox();
this.lblUsuario = new System.Windows.Forms.Label();
this.lblContrasenha = new System.Windows.Forms.Label();
this.txtUsuario = new System.Windows.Forms.TextBox();
this.TxtContrasenha = new System.Windows.Forms.TextBox();
this.btnListarBBDD = new System.Windows.Forms.Button();
this.lsvBBDD = new System.Windows.Forms.ListView();
this.colDBName = new System.Windows.Forms.ColumnHeader();
this.colFechaCreacion = new System.Windows.Forms.ColumnHeader();
this.SuspendLayout();
//
// lsvServidores
//
this.lsvServidores.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)));
this.lsvServidores.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
this.colNombreServidor,
this.colInstancia,
this.colVersion});
this.lsvServidores.Location = new System.Drawing.Point(12, 42);
this.lsvServidores.Name = "lsvServidores";
this.lsvServidores.Size = new System.Drawing.Size(281, 391);
this.lsvServidores.TabIndex = 1;
this.lsvServidores.UseCompatibleStateImageBehavior = false;
this.lsvServidores.View = System.Windows.Forms.View.Details;
this.lsvServidores.SelectedIndexChanged += new System.EventHandler(this.lsvServidores_SelectedIndexChanged);
//
// btnListarServidores
//
this.btnListarServidores.Location = new System.Drawing.Point(12, 13);
this.btnListarServidores.Name = "btnListarServidores";
this.btnListarServidores.Size = new System.Drawing.Size(281, 23);
this.btnListarServidores.TabIndex = 2;
this.btnListarServidores.Text = "Listar Servidores";
this.btnListarServidores.UseVisualStyleBackColor = true;
this.btnListarServidores.Click += new System.EventHandler(this.btnListarServidores_Click);
//
// colNombreServidor
//
this.colNombreServidor.Text = "Servidor";
this.colNombreServidor.Width = 110;
//
// colInstancia
//
this.colInstancia.Text = "Instancia";
this.colInstancia.Width = 94;
//
// colVersion
//
this.colVersion.Text = "Version";
this.colVersion.Width = 73;
//
// lblServidor
//
this.lblServidor.AutoSize = true;
this.lblServidor.Location = new System.Drawing.Point(319, 18);
this.lblServidor.Name = "lblServidor";
this.lblServidor.Size = new System.Drawing.Size(46, 13);
this.lblServidor.TabIndex = 3;
this.lblServidor.Text = "Servidor";
//
// txtServidor
//
this.txtServidor.Location = new System.Drawing.Point(429, 15);
this.txtServidor.Name = "txtServidor";
this.txtServidor.Size = new System.Drawing.Size(180, 20);
this.txtServidor.TabIndex = 4;
//
// lblUsuario
//
this.lblUsuario.AutoSize = true;
this.lblUsuario.Location = new System.Drawing.Point(319, 45);
this.lblUsuario.Name = "lblUsuario";
this.lblUsuario.Size = new System.Drawing.Size(43, 13);
this.lblUsuario.TabIndex = 5;
this.lblUsuario.Text = "Usuario";
//
// lblContrasenha
//
this.lblContrasenha.AutoSize = true;
this.lblContrasenha.Location = new System.Drawing.Point(319, 70);
this.lblContrasenha.Name = "lblContrasenha";
this.lblContrasenha.Size = new System.Drawing.Size(61, 13);
this.lblContrasenha.TabIndex = 6;
this.lblContrasenha.Text = "Contraseña";
//
// txtUsuario
//
this.txtUsuario.Location = new System.Drawing.Point(429, 42);
this.txtUsuario.Name = "txtUsuario";
this.txtUsuario.Size = new System.Drawing.Size(180, 20);
this.txtUsuario.TabIndex = 7;
//
// TxtContrasenha
//
this.TxtContrasenha.Location = new System.Drawing.Point(429, 67);
this.TxtContrasenha.Name = "TxtContrasenha";
this.TxtContrasenha.Size = new System.Drawing.Size(180, 20);
this.TxtContrasenha.TabIndex = 8;
this.TxtContrasenha.UseSystemPasswordChar = true;
//
// btnListarBBDD
//
this.btnListarBBDD.Location = new System.Drawing.Point(322, 93);
this.btnListarBBDD.Name = "btnListarBBDD";
this.btnListarBBDD.Size = new System.Drawing.Size(287, 23);
this.btnListarBBDD.TabIndex = 9;
this.btnListarBBDD.Text = "Listar BBDD";
this.btnListarBBDD.UseVisualStyleBackColor = true;
this.btnListarBBDD.Click += new System.EventHandler(this.btnListarBBDD_Click);
//
// lsvBBDD
//
this.lsvBBDD.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)));
this.lsvBBDD.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
this.colDBName,
this.colFechaCreacion});
this.lsvBBDD.Location = new System.Drawing.Point(322, 122);
this.lsvBBDD.Name = "lsvBBDD";
this.lsvBBDD.Size = new System.Drawing.Size(287, 311);
this.lsvBBDD.TabIndex = 11;
this.lsvBBDD.UseCompatibleStateImageBehavior = false;
this.lsvBBDD.View = System.Windows.Forms.View.Details;
this.lsvBBDD.DoubleClick += new System.EventHandler(this.lsvBBDD_DoubleClick);
//
// colDBName
//
this.colDBName.Text = "Base de Datos";
this.colDBName.Width = 165;
//
// colFechaCreacion
//
this.colFechaCreacion.Text = "Fecha de Creacion";
this.colFechaCreacion.Width = 107;
//
// frmServidores
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(631, 445);
this.Controls.Add(this.lsvBBDD);
this.Controls.Add(this.btnListarBBDD);
this.Controls.Add(this.TxtContrasenha);
this.Controls.Add(this.txtUsuario);
this.Controls.Add(this.lblContrasenha);
this.Controls.Add(this.lblUsuario);
this.Controls.Add(this.txtServidor);
this.Controls.Add(this.lblServidor);
this.Controls.Add(this.btnListarServidores);
this.Controls.Add(this.lsvServidores);
this.Name = "frmServidores";
this.Text = "Servidores";
this.Load += new System.EventHandler(this.Form1_Load);
this.ResumeLayout(false);
this.PerformLayout();
}
#endregion
private System.Windows.Forms.ListView lsvServidores;
private System.Windows.Forms.Button btnListarServidores;
private System.Windows.Forms.ColumnHeader colNombreServidor;
private System.Windows.Forms.ColumnHeader colInstancia;
private System.Windows.Forms.ColumnHeader colVersion;
private System.Windows.Forms.Label lblServidor;
private System.Windows.Forms.TextBox txtServidor;
private System.Windows.Forms.Label lblUsuario;
private System.Windows.Forms.Label lblContrasenha;
private System.Windows.Forms.TextBox txtUsuario;
private System.Windows.Forms.TextBox TxtContrasenha;
private System.Windows.Forms.Button btnListarBBDD;
private System.Windows.Forms.ListView lsvBBDD;
private System.Windows.Forms.ColumnHeader colDBName;
private System.Windows.Forms.ColumnHeader colFechaCreacion;
}
}

View File

@@ -1,121 +0,0 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using System.Data.Sql;
using System.Data.SqlClient;
using System.Data.SqlTypes;
namespace ServerExplorer
{
public partial class frmServidores : Form
{
public frmServidores()
{
InitializeComponent();
}
private void Form1_Load(object sender, EventArgs e)
{
}
private void btnListarServidores_Click(object sender, EventArgs e)
{
// Obtener listado de servidores
SqlDataSourceEnumerator enumerador = SqlDataSourceEnumerator.Instance;
DataTable servidores = enumerador.GetDataSources();
lsvServidores.Items.Clear();
lsvBBDD.Items.Clear();
foreach (DataRow dr in servidores.Rows)
{
// Nombre del servidor
ListViewItem item = lsvServidores.Items.Add((String)dr["ServerName"]);
// Nombre de la instancia
if (dr["InstanceName"] == System.DBNull.Value)
{
item.SubItems.Add("");
}
else
{
item.SubItems.Add((String)dr["InstanceName"]);
}
// Numero de version
if (dr["Version"] == System.DBNull.Value)
{
item.SubItems.Add("???");
}
else
{
item.SubItems.Add((String)dr["Version"]);
}
}
}
private void lsvServidores_SelectedIndexChanged(object sender, EventArgs e)
{
if (lsvServidores.SelectedItems.Count > 0)
{
ListViewItem item = lsvServidores.SelectedItems[0];
if (item.SubItems[1].Text.CompareTo("")==0)
{
// Servidor sin subinstancias
txtServidor.Text = item.SubItems[0].Text;
}
else
{
// Servidor con subinstancias
txtServidor.Text = item.SubItems[0].Text+"/"+item.SubItems[1].Text;
}
}
}
private void btnListarBBDD_Click(object sender, EventArgs e)
{
// Construir cadena de conexion
SqlConnectionStringBuilder constructor = new SqlConnectionStringBuilder();
constructor.DataSource = txtServidor.Text;
constructor.InitialCatalog = "master";
constructor.UserID = txtUsuario.Text;
constructor.Password = TxtContrasenha.Text;
// Obtener todas las bases de datos
SqlConnection cnx = new SqlConnection(constructor.ConnectionString);
cnx.Open();
DataTable dt = cnx.GetSchema("Databases");
cnx.Close();
// Mostrar bases de datos
lsvBBDD.Items.Clear();
foreach (DataRow dr in dt.Rows)
{
ListViewItem item = lsvBBDD.Items.Add((String)dr["database_name"]);
item.SubItems.Add(((DateTime)dr["create_date"]).ToShortDateString());
}
}
private void lsvBBDD_DoubleClick(object sender, EventArgs e)
{
if (lsvBBDD.SelectedItems.Count == 1)
{
// Construir cadena de conexion final
SqlConnectionStringBuilder constructor = new SqlConnectionStringBuilder();
constructor.DataSource = txtServidor.Text;
constructor.InitialCatalog = (String)lsvBBDD.SelectedItems[0].SubItems[0].Text;
constructor.UserID = txtUsuario.Text;
constructor.Password = TxtContrasenha.Text;
// Llamar a la venta de la base de datos
frmBaseDatos frm = new frmBaseDatos(constructor.ConnectionString);
frm.Show();
}
}
}
}

View File

@@ -1,120 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

Binary file not shown.

View File

@@ -1,9 +1,8 @@
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Xml.Serialization;
using System.IO; using System.IO;
using System.Runtime.Serialization;
using System.Xml.Serialization;
namespace ServerExplorer namespace ServerExplorer
{ {
@@ -14,21 +13,41 @@ namespace ServerExplorer
public String PathDAL=""; public String PathDAL="";
public String PathDTO=""; public String PathDTO="";
public String PathExtra=""; public String PathExtra="";
public List<CodeGenTablaInfo> Tablas = new List<CodeGenTablaInfo>();
public List<String> tablas=new List<String>();
public CodeGenConfig()
{
// Nada
}
public void Guardar(String fichero){ public void Guardar(String fichero){
XmlSerializer seriador = new XmlSerializer(typeof(CodeGenConfig)); Type[] tipos={typeof(CodeGenTablaInfo)};
XmlSerializer seriador = new XmlSerializer(typeof(CodeGenConfig), tipos);
StreamWriter escritor = new StreamWriter(fichero); StreamWriter escritor = new StreamWriter(fichero);
seriador.Serialize(escritor, this); seriador.Serialize(escritor, this);
} }
public static CodeGenConfig Cargar(String fichero) public static CodeGenConfig Cargar(String fichero)
{ {
XmlSerializer seriador = new XmlSerializer(typeof(CodeGenConfig)); Type[] tipos = { typeof(CodeGenTablaInfo) };
XmlSerializer seriador = new XmlSerializer(typeof(CodeGenConfig), tipos);
StreamReader lector = new StreamReader(fichero); StreamReader lector = new StreamReader(fichero);
CodeGenConfig config=(CodeGenConfig)seriador.Deserialize(lector); CodeGenConfig config = (CodeGenConfig)seriador.Deserialize(lector);
return config; return config;
} }
}
public class CodeGenTablaInfo
{
public String Esquema="";
public String Nombre="";
public CodeGenTablaInfo() { }
public CodeGenTablaInfo(String esquema, String nombre)
{
Esquema = esquema;
Nombre = nombre;
}
} }
} }

View File

@@ -152,4 +152,4 @@
<Target Name="AfterBuild"> <Target Name="AfterBuild">
</Target> </Target>
--> -->
</Project> </Project>

View File

@@ -39,13 +39,12 @@
this.colNombreColumna = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader())); this.colNombreColumna = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
this.colTipoDatos = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader())); this.colTipoDatos = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
this.colTamanho = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader())); this.colTamanho = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
this.dataGridView1 = new System.Windows.Forms.DataGridView();
this.menuBaseDatos = new System.Windows.Forms.MenuStrip(); this.menuBaseDatos = new System.Windows.Forms.MenuStrip();
this.archivoToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.archivoToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.menuCargar = new System.Windows.Forms.ToolStripMenuItem(); this.menuCargar = new System.Windows.Forms.ToolStripMenuItem();
this.menuGuardar = new System.Windows.Forms.ToolStripMenuItem(); this.menuGuardar = new System.Windows.Forms.ToolStripMenuItem();
this.menuConfiguracion = new System.Windows.Forms.ToolStripMenuItem(); this.menuConfiguracion = new System.Windows.Forms.ToolStripMenuItem();
((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).BeginInit(); this.colClave = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
this.menuBaseDatos.SuspendLayout(); this.menuBaseDatos.SuspendLayout();
this.SuspendLayout(); this.SuspendLayout();
// //
@@ -56,7 +55,7 @@
this.txtConString.Location = new System.Drawing.Point(123, 33); this.txtConString.Location = new System.Drawing.Point(123, 33);
this.txtConString.Name = "txtConString"; this.txtConString.Name = "txtConString";
this.txtConString.ReadOnly = true; this.txtConString.ReadOnly = true;
this.txtConString.Size = new System.Drawing.Size(472, 20); this.txtConString.Size = new System.Drawing.Size(507, 20);
this.txtConString.TabIndex = 0; this.txtConString.TabIndex = 0;
// //
// lblConString // lblConString
@@ -71,7 +70,7 @@
// btnCopiarConString // btnCopiarConString
// //
this.btnCopiarConString.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); this.btnCopiarConString.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.btnCopiarConString.Location = new System.Drawing.Point(601, 31); this.btnCopiarConString.Location = new System.Drawing.Point(636, 31);
this.btnCopiarConString.Name = "btnCopiarConString"; this.btnCopiarConString.Name = "btnCopiarConString";
this.btnCopiarConString.Size = new System.Drawing.Size(52, 23); this.btnCopiarConString.Size = new System.Drawing.Size(52, 23);
this.btnCopiarConString.TabIndex = 3; this.btnCopiarConString.TabIndex = 3;
@@ -113,16 +112,18 @@
// //
// lsvColumnas // lsvColumnas
// //
this.lsvColumnas.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) this.lsvColumnas.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right))); | System.Windows.Forms.AnchorStyles.Right)));
this.lsvColumnas.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] { this.lsvColumnas.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
this.colNombreColumna, this.colNombreColumna,
this.colTipoDatos, this.colTipoDatos,
this.colTamanho}); this.colTamanho,
this.colClave});
this.lsvColumnas.FullRowSelect = true; this.lsvColumnas.FullRowSelect = true;
this.lsvColumnas.Location = new System.Drawing.Point(344, 59); this.lsvColumnas.Location = new System.Drawing.Point(344, 59);
this.lsvColumnas.Name = "lsvColumnas"; this.lsvColumnas.Name = "lsvColumnas";
this.lsvColumnas.Size = new System.Drawing.Size(309, 241); this.lsvColumnas.Size = new System.Drawing.Size(344, 405);
this.lsvColumnas.TabIndex = 6; this.lsvColumnas.TabIndex = 6;
this.lsvColumnas.UseCompatibleStateImageBehavior = false; this.lsvColumnas.UseCompatibleStateImageBehavior = false;
this.lsvColumnas.View = System.Windows.Forms.View.Details; this.lsvColumnas.View = System.Windows.Forms.View.Details;
@@ -130,28 +131,17 @@
// colNombreColumna // colNombreColumna
// //
this.colNombreColumna.Text = "Columna"; this.colNombreColumna.Text = "Columna";
this.colNombreColumna.Width = 139; this.colNombreColumna.Width = 122;
// //
// colTipoDatos // colTipoDatos
// //
this.colTipoDatos.Text = "Tipo de Datos"; this.colTipoDatos.Text = "Tipo de Datos";
this.colTipoDatos.Width = 92; this.colTipoDatos.Width = 81;
// //
// colTamanho // colTamanho
// //
this.colTamanho.Text = "Tamaño"; this.colTamanho.Text = "Tamaño";
// //
// dataGridView1
//
this.dataGridView1.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.dataGridView1.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.dataGridView1.Location = new System.Drawing.Point(344, 306);
this.dataGridView1.Name = "dataGridView1";
this.dataGridView1.Size = new System.Drawing.Size(309, 158);
this.dataGridView1.TabIndex = 8;
//
// menuBaseDatos // menuBaseDatos
// //
this.menuBaseDatos.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { this.menuBaseDatos.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
@@ -159,7 +149,7 @@
this.menuConfiguracion}); this.menuConfiguracion});
this.menuBaseDatos.Location = new System.Drawing.Point(0, 0); this.menuBaseDatos.Location = new System.Drawing.Point(0, 0);
this.menuBaseDatos.Name = "menuBaseDatos"; this.menuBaseDatos.Name = "menuBaseDatos";
this.menuBaseDatos.Size = new System.Drawing.Size(665, 24); this.menuBaseDatos.Size = new System.Drawing.Size(700, 24);
this.menuBaseDatos.TabIndex = 9; this.menuBaseDatos.TabIndex = 9;
this.menuBaseDatos.Text = "menuBaseDatos"; this.menuBaseDatos.Text = "menuBaseDatos";
// //
@@ -193,12 +183,16 @@
this.menuConfiguracion.Text = "Configuracion"; this.menuConfiguracion.Text = "Configuracion";
this.menuConfiguracion.Click += new System.EventHandler(this.menuConfiguracion_Click); this.menuConfiguracion.Click += new System.EventHandler(this.menuConfiguracion_Click);
// //
// colClave
//
this.colClave.Text = "Clave";
this.colClave.Width = 71;
//
// frmBaseDatos // frmBaseDatos
// //
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(665, 476); this.ClientSize = new System.Drawing.Size(700, 476);
this.Controls.Add(this.dataGridView1);
this.Controls.Add(this.lsvColumnas); this.Controls.Add(this.lsvColumnas);
this.Controls.Add(this.lsvTablas); this.Controls.Add(this.lsvTablas);
this.Controls.Add(this.btnCopiarConString); this.Controls.Add(this.btnCopiarConString);
@@ -209,7 +203,6 @@
this.Name = "frmBaseDatos"; this.Name = "frmBaseDatos";
this.Text = "Base de Datos"; this.Text = "Base de Datos";
this.Load += new System.EventHandler(this.frmBaseDatos_Load); this.Load += new System.EventHandler(this.frmBaseDatos_Load);
((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).EndInit();
this.menuBaseDatos.ResumeLayout(false); this.menuBaseDatos.ResumeLayout(false);
this.menuBaseDatos.PerformLayout(); this.menuBaseDatos.PerformLayout();
this.ResumeLayout(false); this.ResumeLayout(false);
@@ -230,11 +223,11 @@
private System.Windows.Forms.ColumnHeader colNombreColumna; private System.Windows.Forms.ColumnHeader colNombreColumna;
private System.Windows.Forms.ColumnHeader colTipoDatos; private System.Windows.Forms.ColumnHeader colTipoDatos;
private System.Windows.Forms.ColumnHeader colTamanho; private System.Windows.Forms.ColumnHeader colTamanho;
private System.Windows.Forms.DataGridView dataGridView1;
private System.Windows.Forms.MenuStrip menuBaseDatos; private System.Windows.Forms.MenuStrip menuBaseDatos;
private System.Windows.Forms.ToolStripMenuItem archivoToolStripMenuItem; private System.Windows.Forms.ToolStripMenuItem archivoToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem menuCargar; private System.Windows.Forms.ToolStripMenuItem menuCargar;
private System.Windows.Forms.ToolStripMenuItem menuGuardar; private System.Windows.Forms.ToolStripMenuItem menuGuardar;
private System.Windows.Forms.ToolStripMenuItem menuConfiguracion; private System.Windows.Forms.ToolStripMenuItem menuConfiguracion;
private System.Windows.Forms.ColumnHeader colClave;
} }
} }

View File

@@ -45,14 +45,15 @@ namespace ServerExplorer
// en el listview a la configuracion // en el listview a la configuracion
private void tablas_delistview() private void tablas_delistview()
{ {
config.tablas.Clear(); config.Tablas.Clear();
foreach (ListViewItem item in lsvTablas.Items) foreach (ListViewItem item in lsvTablas.Items)
{ {
if (item.Checked) if (item.Checked)
{ {
config.tablas.Add( config.Tablas.Add(new CodeGenTablaInfo(
item.SubItems[1].Text+ // Esquema item.SubItems[1].Text, // Esquema
item.SubItems[0].Text); // Nombre tabla item.SubItems[0].Text // Nombre tabla
));
} }
} }
} }
@@ -61,10 +62,10 @@ namespace ServerExplorer
// en le listview desde la configuracion // en le listview desde la configuracion
private void tablas_alistview() private void tablas_alistview()
{ {
int i, j,n; int i,j,n;
// Desmarcar todos en caso de no haber ninguna tabla // Desmarcar todos en caso de no haber ninguna tabla
if (config.tablas.Count == 0) if (config.Tablas.Count == 0)
{ {
foreach (ListViewItem item in lsvTablas.Items) foreach (ListViewItem item in lsvTablas.Items)
item.Checked = false; item.Checked = false;
@@ -72,7 +73,7 @@ namespace ServerExplorer
} }
// Recorrer items marcando los que estan en la configuracion // Recorrer items marcando los que estan en la configuracion
n=config.tablas.Count; n=config.Tablas.Count;
i=j=0; i=j=0;
foreach (ListViewItem item in lsvTablas.Items) foreach (ListViewItem item in lsvTablas.Items)
{ {
@@ -81,7 +82,11 @@ namespace ServerExplorer
item.SubItems[1].Text + // Esquema item.SubItems[1].Text + // Esquema
item.SubItems[0].Text; // Nombre tabla item.SubItems[0].Text; // Nombre tabla
do{ do{
if( config.tablas[i].CompareTo(tablename) == 0){ if( config.Tablas[i].Esquema.
CompareTo(item.SubItems[1].Text) == 0 &&
config.Tablas[i].Nombre.
CompareTo(item.SubItems[0].Text) == 0)
{
item.Checked=true; item.Checked=true;
break; break;
} }
@@ -128,18 +133,19 @@ namespace ServerExplorer
// Determinar tabla seleccionada // Determinar tabla seleccionada
ListViewItem item = lsvTablas.SelectedItems[0]; ListViewItem item = lsvTablas.SelectedItems[0];
/*
// Obtener las columnas de la tabla // Obtener las columnas de la tabla
String[] restr_columna = { null, null, item.SubItems[0].Text, null }; String[] restr_columna = { null, null, item.SubItems[0].Text, null };
// NOTA: Catalog, Owner, Table, TableType // NOTA: Catalog, Owner, Table, TableType
cnx.Open(); cnx.Open();
dt = cnx.GetSchema("Columns", restr_columna); dt = cnx.GetSchema("Columns", restr_columna);
dt.DefaultView.Sort="ORDINAL_POSITION";
cnx.Close(); cnx.Close();
// Mostrar "columnas" de las tablas // Mostrar "columnas" de las tablas
lsvColumnas.Items.Clear(); lsvColumnas.Items.Clear();
foreach (DataRow dr in dt.Rows) foreach (DataRowView dr in dt.DefaultView)
{ {
ListViewItem subitem = lsvColumnas.Items.Add((String)dr["COLUMN_NAME"]); ListViewItem subitem = lsvColumnas.Items.Add((String)dr["COLUMN_NAME"]);
subitem.SubItems.Add((String)dr["DATA_TYPE"]); subitem.SubItems.Add((String)dr["DATA_TYPE"]);
@@ -148,18 +154,55 @@ namespace ServerExplorer
subitem.SubItems.Add(String.Format("{0}",dr["CHARACTER_MAXIMUM_LENGTH"])); subitem.SubItems.Add(String.Format("{0}",dr["CHARACTER_MAXIMUM_LENGTH"]));
} }
} }
*/
// Obtener las restricciones de la tabla // Obtener informacion de las columnas de la tabla
SqlDataAdapter da = new SqlDataAdapter(
"select col.COLUMN_NAME as Columna, "+
" col.DATA_TYPE as Tipo, "+
" col.CHARACTER_MAXIMUM_LENGTH as Tamanho, "+
" c.CONSTRAINT_TYPE as TipoClave "+
" from INFORMATION_SCHEMA.COLUMNS as col "+
" left join INFORMATION_SCHEMA.KEY_COLUMN_USAGE as k " +
" on col.COLUMN_NAME=k.COLUMN_NAME and "+
" col.TABLE_NAME=k.TABLE_NAME and "+
" col.TABLE_SCHEMA=k.TABLE_SCHEMA "+
" left join INFORMATION_SCHEMA.TABLE_CONSTRAINTS as c "+
" on k.CONSTRAINT_NAME=c.CONSTRAINT_NAME "+
" WHERE col.TABLE_NAME=@nombreTabla AND "+
" col.TABLE_SCHEMA=@nombreEsquema "+
" order by col.ORDINAL_POSITION",
cnx);
da.SelectCommand.Parameters.AddWithValue("@nombreTabla", item.SubItems[0].Text);
da.SelectCommand.Parameters.AddWithValue("@nombreEsquema",item.SubItems[1].Text);
dt = new DataTable();
cnx.Open(); cnx.Open();
dt = cnx.GetSchema("Restrictions"); da.Fill(dt);
dt = cnx.GetSchema("ForeignKeys");
//dt = cnx.GetSchema("Indexes");
//dt = cnx.GetSchema("IndexColumns");
//dt = cnx.GetSchema("Constraint");
cnx.Close(); cnx.Close();
// Mostrar las columnas de la tabla restricciones // Mostrar "columnas" de las tablas
dataGridView1.DataSource = dt; lsvColumnas.Items.Clear();
foreach (DataRow dr in dt.Rows)
{
ListViewItem subitem = lsvColumnas.Items.Add((String)dr["Columna"]);
subitem.SubItems.Add((String)dr["Tipo"]);
if (dr["Tamanho"] != DBNull.Value)
{
subitem.SubItems.Add(String.Format("{0}", dr["Tamanho"]));
}
else
{
subitem.SubItems.Add("");
}
if (dr["TipoClave"] != DBNull.Value)
{
subitem.SubItems.Add((String)dr["TipoClave"]);
}
else
{
subitem.SubItems.Add("");
}
}
} }
} }

View File

@@ -1,30 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?><?xml-stylesheet type='text/xsl' href='_UpgradeReport_Files/UpgradeReport.xslt'?><UpgradeLog>
<Properties><Property Name="Solution" Value="ServerExplorer">
</Property><Property Name="Archivo de la solución" Value="C:\Users\val\Desktop\ServerExplorer\ServerExplorer.sln">
</Property><Property Name="Archivo de opciones de usuario" Value="C:\Users\val\Desktop\ServerExplorer\ServerExplorer.suo">
</Property><Property Name="Date" Value="miércoles, 28 de marzo de 2012">
</Property><Property Name="Time" Value="14:40">
</Property></Properties><Event ErrorLevel="0" Project="" Source="ServerExplorer.sln" Description="La copia C:\Users\val\Desktop\ServerExplorer\Backup\ServerExplorer.sln del archivo se ha realizado correctamente">
</Event><Event ErrorLevel="0" Project="" Source="ServerExplorer.suo" Description="La copia C:\Users\val\Desktop\ServerExplorer\Backup\ServerExplorer.suo del archivo se ha realizado correctamente">
</Event><Event ErrorLevel="0" Project="ServerExplorer" Source="ServerExplorer\ServerExplorer.csproj" Description="Se realizó correctamente la copia de seguridad del archivo de proyecto C:\Users\val\Desktop\ServerExplorer\Backup\ServerExplorer\ServerExplorer.csproj">
</Event><Event ErrorLevel="0" Project="ServerExplorer" Source="ServerExplorer\frmBaseDatos.cs" Description="Se realizó correctamente la copia de seguridad del archivo C:\Users\val\Desktop\ServerExplorer\Backup\ServerExplorer\frmBaseDatos.cs">
</Event><Event ErrorLevel="0" Project="ServerExplorer" Source="ServerExplorer\frmBaseDatos.Designer.cs" Description="Se realizó correctamente la copia de seguridad del archivo C:\Users\val\Desktop\ServerExplorer\Backup\ServerExplorer\frmBaseDatos.Designer.cs">
</Event><Event ErrorLevel="0" Project="ServerExplorer" Source="ServerExplorer\frmPrincipal.cs" Description="Se realizó correctamente la copia de seguridad del archivo C:\Users\val\Desktop\ServerExplorer\Backup\ServerExplorer\frmPrincipal.cs">
</Event><Event ErrorLevel="0" Project="ServerExplorer" Source="ServerExplorer\frmPrincipal.Designer.cs" Description="Se realizó correctamente la copia de seguridad del archivo C:\Users\val\Desktop\ServerExplorer\Backup\ServerExplorer\frmPrincipal.Designer.cs">
</Event><Event ErrorLevel="0" Project="ServerExplorer" Source="ServerExplorer\frmServidores.cs" Description="Se realizó correctamente la copia de seguridad del archivo C:\Users\val\Desktop\ServerExplorer\Backup\ServerExplorer\frmServidores.cs">
</Event><Event ErrorLevel="0" Project="ServerExplorer" Source="ServerExplorer\frmServidores.Designer.cs" Description="Se realizó correctamente la copia de seguridad del archivo C:\Users\val\Desktop\ServerExplorer\Backup\ServerExplorer\frmServidores.Designer.cs">
</Event><Event ErrorLevel="0" Project="ServerExplorer" Source="ServerExplorer\Program.cs" Description="Se realizó correctamente la copia de seguridad del archivo C:\Users\val\Desktop\ServerExplorer\Backup\ServerExplorer\Program.cs">
</Event><Event ErrorLevel="0" Project="ServerExplorer" Source="ServerExplorer\Properties\AssemblyInfo.cs" Description="Se realizó correctamente la copia de seguridad del archivo C:\Users\val\Desktop\ServerExplorer\Backup\ServerExplorer\Properties\AssemblyInfo.cs">
</Event><Event ErrorLevel="0" Project="ServerExplorer" Source="ServerExplorer\Properties\Resources.Designer.cs" Description="Se realizó correctamente la copia de seguridad del archivo C:\Users\val\Desktop\ServerExplorer\Backup\ServerExplorer\Properties\Resources.Designer.cs">
</Event><Event ErrorLevel="0" Project="ServerExplorer" Source="ServerExplorer\Properties\Settings.Designer.cs" Description="Se realizó correctamente la copia de seguridad del archivo C:\Users\val\Desktop\ServerExplorer\Backup\ServerExplorer\Properties\Settings.Designer.cs">
</Event><Event ErrorLevel="0" Project="ServerExplorer" Source="ServerExplorer\Properties\Settings.settings" Description="Se realizó correctamente la copia de seguridad del archivo C:\Users\val\Desktop\ServerExplorer\Backup\ServerExplorer\Properties\Settings.settings">
</Event><Event ErrorLevel="0" Project="ServerExplorer" Source="ServerExplorer\frmBaseDatos.resx" Description="Se realizó correctamente la copia de seguridad del archivo C:\Users\val\Desktop\ServerExplorer\Backup\ServerExplorer\frmBaseDatos.resx">
</Event><Event ErrorLevel="0" Project="ServerExplorer" Source="ServerExplorer\frmPrincipal.resx" Description="Se realizó correctamente la copia de seguridad del archivo C:\Users\val\Desktop\ServerExplorer\Backup\ServerExplorer\frmPrincipal.resx">
</Event><Event ErrorLevel="0" Project="ServerExplorer" Source="ServerExplorer\frmServidores.resx" Description="Se realizó correctamente la copia de seguridad del archivo C:\Users\val\Desktop\ServerExplorer\Backup\ServerExplorer\frmServidores.resx">
</Event><Event ErrorLevel="0" Project="ServerExplorer" Source="ServerExplorer\Properties\Resources.resx" Description="Se realizó correctamente la copia de seguridad del archivo C:\Users\val\Desktop\ServerExplorer\Backup\ServerExplorer\Properties\Resources.resx">
</Event><Event ErrorLevel="0" Project="ServerExplorer" Source="ServerExplorer\ServerExplorer.csproj" Description="Proyecto convertido correctamente">
</Event><Event ErrorLevel="3" Project="ServerExplorer" Source="ServerExplorer\ServerExplorer.csproj" Description="Converted">
</Event><Event ErrorLevel="0" Project="" Source="ServerExplorer.sln" Description="La solución se convirtió correctamente">
</Event><Event ErrorLevel="3" Project="" Source="ServerExplorer.sln" Description="Converted">
</Event><Event ErrorLevel="0" Project="ServerExplorer" Source="ServerExplorer\ServerExplorer.csproj" Description="Examen completo: no es necesario actualizar los archivos de proyecto.">
</Event></UpgradeLog>

View File

@@ -1,207 +0,0 @@
BODY
{
BACKGROUND-COLOR: white;
FONT-FAMILY: "Verdana", sans-serif;
FONT-SIZE: 100%;
MARGIN-LEFT: 0px;
MARGIN-TOP: 0px
}
P
{
FONT-FAMILY: "Verdana", sans-serif;
FONT-SIZE: 70%;
LINE-HEIGHT: 12pt;
MARGIN-BOTTOM: 0px;
MARGIN-LEFT: 10px;
MARGIN-TOP: 10px
}
.note
{
BACKGROUND-COLOR: #ffffff;
COLOR: #336699;
FONT-FAMILY: "Verdana", sans-serif;
FONT-SIZE: 100%;
MARGIN-BOTTOM: 0px;
MARGIN-LEFT: 0px;
MARGIN-TOP: 0px;
PADDING-RIGHT: 10px
}
.infotable
{
BACKGROUND-COLOR: #f0f0e0;
BORDER-BOTTOM: #ffffff 0px solid;
BORDER-COLLAPSE: collapse;
BORDER-LEFT: #ffffff 0px solid;
BORDER-RIGHT: #ffffff 0px solid;
BORDER-TOP: #ffffff 0px solid;
FONT-SIZE: 70%;
MARGIN-LEFT: 10px
}
.issuetable
{
BACKGROUND-COLOR: #ffffe8;
BORDER-COLLAPSE: collapse;
COLOR: #000000;
FONT-SIZE: 100%;
MARGIN-BOTTOM: 10px;
MARGIN-LEFT: 13px;
MARGIN-TOP: 0px
}
.issuetitle
{
BACKGROUND-COLOR: #ffffff;
BORDER-BOTTOM: #dcdcdc 1px solid;
BORDER-TOP: #dcdcdc 1px;
COLOR: #003366;
FONT-WEIGHT: normal
}
.header
{
BACKGROUND-COLOR: #cecf9c;
BORDER-BOTTOM: #ffffff 1px solid;
BORDER-LEFT: #ffffff 1px solid;
BORDER-RIGHT: #ffffff 1px solid;
BORDER-TOP: #ffffff 1px solid;
COLOR: #000000;
FONT-WEIGHT: bold
}
.issuehdr
{
BACKGROUND-COLOR: #E0EBF5;
BORDER-BOTTOM: #dcdcdc 1px solid;
BORDER-TOP: #dcdcdc 1px solid;
COLOR: #000000;
FONT-WEIGHT: normal
}
.issuenone
{
BACKGROUND-COLOR: #ffffff;
BORDER-BOTTOM: 0px;
BORDER-LEFT: 0px;
BORDER-RIGHT: 0px;
BORDER-TOP: 0px;
COLOR: #000000;
FONT-WEIGHT: normal
}
.content
{
BACKGROUND-COLOR: #e7e7ce;
BORDER-BOTTOM: #ffffff 1px solid;
BORDER-LEFT: #ffffff 1px solid;
BORDER-RIGHT: #ffffff 1px solid;
BORDER-TOP: #ffffff 1px solid;
PADDING-LEFT: 3px
}
.issuecontent
{
BACKGROUND-COLOR: #ffffff;
BORDER-BOTTOM: #dcdcdc 1px solid;
BORDER-TOP: #dcdcdc 1px solid;
PADDING-LEFT: 3px
}
A:link
{
COLOR: #cc6633;
TEXT-DECORATION: underline
}
A:visited
{
COLOR: #cc6633;
}
A:active
{
COLOR: #cc6633;
}
A:hover
{
COLOR: #cc3300;
TEXT-DECORATION: underline
}
H1
{
BACKGROUND-COLOR: #003366;
BORDER-BOTTOM: #336699 6px solid;
COLOR: #ffffff;
FONT-SIZE: 130%;
FONT-WEIGHT: normal;
MARGIN: 0em 0em 0em -20px;
PADDING-BOTTOM: 8px;
PADDING-LEFT: 30px;
PADDING-TOP: 16px
}
H2
{
COLOR: #000000;
FONT-SIZE: 80%;
FONT-WEIGHT: bold;
MARGIN-BOTTOM: 3px;
MARGIN-LEFT: 10px;
MARGIN-TOP: 20px;
PADDING-LEFT: 0px
}
H3
{
COLOR: #000000;
FONT-SIZE: 80%;
FONT-WEIGHT: bold;
MARGIN-BOTTOM: -5px;
MARGIN-LEFT: 10px;
MARGIN-TOP: 20px
}
H4
{
COLOR: #000000;
FONT-SIZE: 70%;
FONT-WEIGHT: bold;
MARGIN-BOTTOM: 0px;
MARGIN-TOP: 15px;
PADDING-BOTTOM: 0px
}
UL
{
COLOR: #000000;
FONT-SIZE: 70%;
LIST-STYLE: square;
MARGIN-BOTTOM: 0pt;
MARGIN-TOP: 0pt
}
OL
{
COLOR: #000000;
FONT-SIZE: 70%;
LIST-STYLE: square;
MARGIN-BOTTOM: 0pt;
MARGIN-TOP: 0pt
}
LI
{
LIST-STYLE: square;
MARGIN-LEFT: 0px
}
.expandable
{
CURSOR: hand
}
.expanded
{
color: black
}
.collapsed
{
DISPLAY: none
}
.foot
{
BACKGROUND-COLOR: #ffffff;
BORDER-BOTTOM: #cecf9c 1px solid;
BORDER-TOP: #cecf9c 2px solid
}
.settings
{
MARGIN-LEFT: 25PX;
}
.help
{
TEXT-ALIGN: right;
margin-right: 10px;
}

View File

@@ -1,232 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:msxsl="urn:schemas-microsoft-com:xslt">
<xsl:key name="ProjectKey" match="Event" use="@Project"/>
<xsl:template match="Events" mode="createProjects">
<projects>
<xsl:for-each select="Event">
<!--xsl:sort select="@Project" order="descending"/-->
<xsl:if test="(1=position()) or (preceding-sibling::*[1]/@Project != @Project)">
<xsl:variable name="ProjectName" select="@Project"/>
<project>
<xsl:attribute name="name">
<xsl:value-of select="@Project"/>
</xsl:attribute>
<xsl:if test="@Project=''">
<xsl:attribute name="solution">
<xsl:value-of select="@Solution"/>
</xsl:attribute>
</xsl:if>
<xsl:for-each select="key('ProjectKey', $ProjectName)">
<!--xsl:sort select="@Source" /-->
<xsl:if test="(1=position()) or (preceding-sibling::*[1]/@Source != @Source)">
<source>
<xsl:attribute name="name">
<xsl:value-of select="@Source"/>
</xsl:attribute>
<xsl:variable name="Source">
<xsl:value-of select="@Source"/>
</xsl:variable>
<xsl:for-each select="key('ProjectKey', $ProjectName)[ @Source = $Source ]">
<event>
<xsl:attribute name="error-level">
<xsl:value-of select="@ErrorLevel"/>
</xsl:attribute>
<xsl:attribute name="description">
<xsl:value-of select="@Description"/>
</xsl:attribute>
</event>
</xsl:for-each>
</source>
</xsl:if>
</xsl:for-each>
</project>
</xsl:if>
</xsl:for-each>
</projects>
</xsl:template>
<xsl:template match="projects">
<xsl:for-each select="project">
<xsl:sort select="@Name" order="ascending"/>
<h2>
<xsl:if test="@solution"><a _locID="Solution">Solución</a>: <xsl:value-of select="@solution"/></xsl:if>
<xsl:if test="not(@solution)"><a _locID="Project">Proyecto</a>: <xsl:value-of select="@name"/>
<xsl:for-each select="source">
<xsl:variable name="Hyperlink" select="@name"/>
<xsl:for-each select="event[@error-level='4']">
<A class="note"><xsl:attribute name="HREF"><xsl:value-of select="$Hyperlink"/></xsl:attribute><xsl:value-of select="@description"/></A>
</xsl:for-each>
</xsl:for-each>
</xsl:if>
</h2>
<table cellpadding="2" cellspacing="0" width="98%" border="1" bordercolor="white" class="infotable">
<tr>
<td nowrap="1" class="header" _locID="Filename">Nombre de archivo</td>
<td nowrap="1" class="header" _locID="Status">Estado</td>
<td nowrap="1" class="header" _locID="Errors">Errores</td>
<td nowrap="1" class="header" _locID="Warnings">Advertencias</td>
</tr>
<xsl:for-each select="source">
<xsl:sort select="@name" order="ascending"/>
<xsl:variable name="source-id" select="generate-id(.)"/>
<xsl:if test="count(event)!=count(event[@error-level='4'])">
<tr class="row">
<td class="content">
<A HREF="javascript:"><xsl:attribute name="onClick">javascript:document.images['<xsl:value-of select="$source-id"/>'].click()</xsl:attribute><IMG border="0" _locID="IMG.alt" _locAttrData="alt" alt="expandir o contraer sección" class="expandable" height="11" onclick="changepic()" src="_UpgradeReport_Files/UpgradeReport_Plus.gif" width="9"><xsl:attribute name="name"><xsl:value-of select="$source-id"/></xsl:attribute><xsl:attribute name="child">src<xsl:value-of select="$source-id"/></xsl:attribute></IMG></A> <xsl:value-of select="@name"/>
</td>
<td class="content">
<xsl:if test="count(event[@error-level='3'])=1">
<xsl:for-each select="event[@error-level='3']">
<xsl:if test="@description='Converted'"><a _locID="Converted1">Convertido</a></xsl:if>
<xsl:if test="@description!='Converted'"><xsl:value-of select="@description"/></xsl:if>
</xsl:for-each>
</xsl:if>
<xsl:if test="count(event[@error-level='3'])!=1 and count(event[@error-level='3' and @description='Converted'])!=0"><a _locID="Converted2">Convertido</a>
</xsl:if>
</td>
<td class="content"><xsl:value-of select="count(event[@error-level='2'])"/></td>
<td class="content"><xsl:value-of select="count(event[@error-level='1'])"/></td>
</tr>
<tr class="collapsed" bgcolor="#ffffff">
<xsl:attribute name="id">src<xsl:value-of select="$source-id"/></xsl:attribute>
<td colspan="7">
<table width="97%" border="1" bordercolor="#dcdcdc" rules="cols" class="issuetable">
<tr>
<td colspan="7" class="issuetitle" _locID="ConversionIssues">Informe de conversión - <xsl:value-of select="@name"/>:</td>
</tr>
<xsl:for-each select="event[@error-level!='3']">
<xsl:if test="@error-level!='4'">
<tr>
<td class="issuenone" style="border-bottom:solid 1 lightgray">
<xsl:value-of select="@description"/>
</td>
</tr>
</xsl:if>
</xsl:for-each>
</table>
</td>
</tr>
</xsl:if>
</xsl:for-each>
<tr valign="top">
<td class="foot">
<xsl:if test="count(source)!=1">
<xsl:value-of select="count(source)"/><a _locID="file1"> archivos</a>
</xsl:if>
<xsl:if test="count(source)=1">
<a _locID="file2">1 archivo</a>
</xsl:if>
</td>
<td class="foot">
<a _locID="Converted3">Convertido</a>: <xsl:value-of select="count(source/event[@error-level='3' and @description='Converted'])"/><BR/>
<a _locID="NotConverted">No convertido</a>: <xsl:value-of select="count(source) - count(source/event[@error-level='3' and @description='Converted'])"/>
</td>
<td class="foot"><xsl:value-of select="count(source/event[@error-level='2'])"/></td>
<td class="foot"><xsl:value-of select="count(source/event[@error-level='1'])"/></td>
</tr>
</table>
</xsl:for-each>
</xsl:template>
<xsl:template match="Property">
<xsl:if test="@Name!='Date' and @Name!='Time' and @Name!='LogNumber' and @Name!='Solution'">
<tr><td nowrap="1"><b><xsl:value-of select="@Name"/>: </b><xsl:value-of select="@Value"/></td></tr>
</xsl:if>
</xsl:template>
<xsl:template match="UpgradeLog">
<html>
<head>
<META HTTP-EQUIV="Content-Type" content="text/html; charset=utf-8"/>
<link rel="stylesheet" href="_UpgradeReport_Files\UpgradeReport.css"/>
<title _locID="ConversionReport0">Informe de conversión
<xsl:if test="Properties/Property[@Name='LogNumber']">
<xsl:value-of select="Properties/Property[@Name='LogNumber']/@Value"/>
</xsl:if>
</title>
<script language="javascript">
function outliner () {
oMe = window.event.srcElement
//get child element
var child = document.all[event.srcElement.getAttribute("child",false)];
//if child element exists, expand or collapse it.
if (null != child)
child.className = child.className == "collapsed" ? "expanded" : "collapsed";
}
function changepic() {
uMe = window.event.srcElement;
var check = uMe.src.toLowerCase();
if (check.lastIndexOf("upgradereport_plus.gif") != -1)
{
uMe.src = "_UpgradeReport_Files/UpgradeReport_Minus.gif"
}
else
{
uMe.src = "_UpgradeReport_Files/UpgradeReport_Plus.gif"
}
}
</script>
</head>
<body topmargin="0" leftmargin="0" rightmargin="0" onclick="outliner();">
<h1 _locID="ConversionReport">Informe de conversión - <xsl:value-of select="Properties/Property[@Name='Solution']/@Value"/></h1>
<p><span class="note">
<b _locID="TimeOfConversion">Tiempo de conversión:</b> <xsl:value-of select="Properties/Property[@Name='Date']/@Value"/> <xsl:value-of select="Properties/Property[@Name='Time']/@Value"/><br/>
</span></p>
<xsl:variable name="SortedEvents">
<Events>
<xsl:for-each select="Event">
<xsl:sort select="@Project" order="ascending"/>
<xsl:sort select="@Source" order="ascending"/>
<xsl:sort select="@ErrorLevel" order="ascending"/>
<Event>
<xsl:attribute name="Project"><xsl:value-of select="@Project"/> </xsl:attribute>
<xsl:attribute name="Solution"><xsl:value-of select="/UpgradeLog/Properties/Property[@Name='Solution']/@Value"/> </xsl:attribute>
<xsl:attribute name="Source"><xsl:value-of select="@Source"/> </xsl:attribute>
<xsl:attribute name="ErrorLevel"><xsl:value-of select="@ErrorLevel"/> </xsl:attribute>
<xsl:attribute name="Description"><xsl:value-of select="@Description"/> </xsl:attribute>
</Event>
</xsl:for-each>
</Events>
</xsl:variable>
<xsl:variable name="Projects">
<xsl:apply-templates select="msxsl:node-set($SortedEvents)/*" mode="createProjects"/>
</xsl:variable>
<xsl:apply-templates select="msxsl:node-set($Projects)/*"/>
<p></p><p>
<table class="note">
<tr>
<td nowrap="1">
<b _locID="ConversionSettings">Configuración de conversión</b>
</td>
</tr>
<xsl:apply-templates select="Properties"/>
</table></p>
</body>
</html>
</xsl:template>
</xsl:stylesheet>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 69 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 71 B

BIN
ServerExplorer/ssr.exe Normal file

Binary file not shown.