Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions snippets/csharp/System.Data/EntityKey/Overview/app.config
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<connectionStrings>
<add name="AdventureWorksEntities" connectionString="metadata=res://*/AdventureWorksModel.csdl|res://*/AdventureWorksModel.ssdl|res://*/AdventureWorksModel.msl;provider=System.Data.SqlClient;provider connection string=&quot;Data Source=juliakornich;Initial Catalog=AdventureWorks;Integrated Security=True;MultipleActiveResultSets=True&quot;" providerName="System.Data.EntityClient" />
<add name="SchoolEntities" connectionString="metadata=res://*/School.csdl|res://*/School.ssdl|res://*/School.msl;provider=System.Data.SqlClient;provider connection string=&quot;Data Source=juliakornich;Initial Catalog=School;Integrated Security=True;MultipleActiveResultSets=True&quot;" providerName="System.Data.EntityClient" />
<add name="AdventureWorksEntities" connectionString="metadata=res://*/AdventureWorksModel.csdl|res://*/AdventureWorksModel.ssdl|res://*/AdventureWorksModel.msl;provider=System.Data.SqlClient;provider connection string=&quot;Data Source=localhost;Initial Catalog=AdventureWorks;Integrated Security=True;MultipleActiveResultSets=True&quot;" providerName="System.Data.EntityClient" />
<add name="SchoolEntities" connectionString="metadata=res://*/School.csdl|res://*/School.ssdl|res://*/School.msl;provider=System.Data.SqlClient;provider connection string=&quot;Data Source=localhost;Initial Catalog=School;Integrated Security=True;MultipleActiveResultSets=True&quot;" providerName="System.Data.EntityClient" />
</connectionStrings>
</configuration>
</configuration>

This file was deleted.

This file was deleted.

This file was deleted.

6 changes: 2 additions & 4 deletions snippets/csharp/System/Random/Overview/project.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@
<PropertyGroup>
<OutputType>Library</OutputType>
<TargetFramework>net8.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
</PropertyGroup>
</Project>

</Project>
Original file line number Diff line number Diff line change
@@ -1,13 +1,9 @@
using System;

Check failure on line 1 in snippets/csharp/VS_Snippets_ADO.NET/Classic WebData OdbcCommand/CS/source.cs

View workflow job for this annotation

GitHub Actions / snippets-build

ERROR: Project missing. A project (and optionally a solution file) must be in this directory or one of the parent directories to validate and build this code.
using System.Data;
using System.Data.Odbc;

class Program
{
static void Main()
{
//string connectionString = "Driver={Microsoft Access Driver (*.mdb)};DBQ=C:\\Samples\\Northwind.mdb";
}
// <Snippet1>
public void InsertRow(string connectionString, string insertSQL)
{
Expand All @@ -31,6 +27,6 @@
// The connection is automatically closed when the
// code exits the using block.
}
// </Snippet1>
}
// </Snippet1>
}
Original file line number Diff line number Diff line change
@@ -1,14 +1,9 @@
using System;

Check failure on line 1 in snippets/csharp/VS_Snippets_ADO.NET/Classic WebData OdbcConnection.BeginTransaction/CS/source.cs

View workflow job for this annotation

GitHub Actions / snippets-build

ERROR: Project missing. A project (and optionally a solution file) must be in this directory or one of the parent directories to validate and build this code.
using System.Data;
using System.Data.Odbc;

class Program
{
static void Main()
{
string connectionString = "Driver={Microsoft Access Driver (*.mdb)};DBQ=C:\\Samples\\Northwind.mdb";
ExecuteTransaction(connectionString);
}
// <Snippet1>
public static void ExecuteTransaction(string connectionString)
{
Expand Down Expand Up @@ -61,6 +56,6 @@
// The connection is automatically closed when the
// code exits the using block.
}
// </Snippet1>
}
// </Snippet1>
}
Original file line number Diff line number Diff line change
@@ -1,14 +1,9 @@
using System;

Check failure on line 1 in snippets/csharp/VS_Snippets_ADO.NET/Classic WebData OdbcConnection.BeginTransaction1/CS/source.cs

View workflow job for this annotation

GitHub Actions / snippets-build

ERROR: Project missing. A project (and optionally a solution file) must be in this directory or one of the parent directories to validate and build this code.
using System.Data;
using System.Data.Odbc;

class Program
{
static void Main()
{
string connectionString = "Driver={Microsoft Access Driver (*.mdb)};DBQ=C:\\Samples\\Northwind.mdb";
ExecuteTransaction(connectionString);
}
// <Snippet1>
public static void ExecuteTransaction(string connectionString)
{
Expand Down Expand Up @@ -61,6 +56,6 @@
// The connection is automatically closed when the
// code exits the using block.
}
// </Snippet1>
}
// </Snippet1>
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using System;

Check failure on line 1 in snippets/csharp/VS_Snippets_ADO.NET/Classic WebData OdbcConnection.Close/CS/source.cs

View workflow job for this annotation

GitHub Actions / snippets-build

ERROR: Project missing. A project (and optionally a solution file) must be in this directory or one of the parent directories to validate and build this code.
using System.Collections.Generic;
using System.Text;
using System.Data.Odbc;
Expand All @@ -7,14 +7,6 @@
{
class Program
{
static void Main(string[] args)
{
string connectionString;
connectionString = "Driver={Microsoft Access Driver (*.mdb)};DBQ=C:\\Samples\\Northwind.mdb";

CreateOdbcConnection(connectionString);
}

// <Snippet1>
private static void CreateOdbcConnection(string connectionString)
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using System;

Check failure on line 1 in snippets/csharp/VS_Snippets_ADO.NET/Classic WebData OdbcConnection/CS/source.cs

View workflow job for this annotation

GitHub Actions / snippets-build

ERROR: Project missing. A project (and optionally a solution file) must be in this directory or one of the parent directories to validate and build this code.
using System.Collections.Generic;
using System.Text;
using System.Data.Odbc;
Expand All @@ -7,14 +7,6 @@
{
class Program
{
static void Main()
{
string connectionString;
connectionString = "Driver={Microsoft Access Driver (*.mdb)};DBQ=C:\\Samples\\Northwind.mdb";

InsertRow(connectionString);
}

// <Snippet1>
static private void InsertRow(string connectionString)
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,9 @@
using System;

Check failure on line 1 in snippets/csharp/VS_Snippets_ADO.NET/Classic WebData OdbcDataAdapter.DeleteCommand/CS/source.cs

View workflow job for this annotation

GitHub Actions / snippets-build

ERROR: Project missing. A project (and optionally a solution file) must be in this directory or one of the parent directories to validate and build this code.
using System.Data;
using System.Data.Odbc;

class Program
{
static void Main()
{
//string connectionString = "Driver={Microsoft Access Driver (*.mdb)};DBQ=C:\\Samples\\Northwind.mdb";
//string x = "DRIVER={SQL Server};SERVER=MyServer;Trusted_connection=yes;DATABASE=Northwind;"
}

//<Snippet1>
public static OdbcDataAdapter CreateDataAdapter(
OdbcConnection connection)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,9 @@
using System;

Check failure on line 1 in snippets/csharp/VS_Snippets_ADO.NET/Classic WebData OdbcDataAdapter.InsertCommand/CS/source.cs

View workflow job for this annotation

GitHub Actions / snippets-build

ERROR: Project missing. A project (and optionally a solution file) must be in this directory or one of the parent directories to validate and build this code.
using System.Data;
using System.Data.Odbc;

class Program
{
static void Main()
{
//string connectionString = "Driver={Microsoft Access Driver (*.mdb)};DBQ=C:\\Samples\\Northwind.mdb";
//string x = "DRIVER={SQL Server};SERVER=MyServer;Trusted_connection=yes;DATABASE=Northwind;"
}

//<Snippet1>
public static OdbcDataAdapter CreateDataAdapter(
OdbcConnection connection)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,9 @@
using System;

Check failure on line 1 in snippets/csharp/VS_Snippets_ADO.NET/Classic WebData OdbcDataAdapter.OdbcDataAdapter/CS/source.cs

View workflow job for this annotation

GitHub Actions / snippets-build

ERROR: Project missing. A project (and optionally a solution file) must be in this directory or one of the parent directories to validate and build this code.
using System.Data;
using System.Data.Odbc;

class Program
{
static void Main()
{
//string connectionString = "Driver={Microsoft Access Driver (*.mdb)};DBQ=C:\\Samples\\Northwind.mdb";
//string x = "DRIVER={SQL Server};SERVER=MyServer;Trusted_connection=yes;DATABASE=Northwind;"
}

//<Snippet1>
public static OdbcDataAdapter CreateDataAdapter(
OdbcConnection connection)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,9 @@
using System;

Check failure on line 1 in snippets/csharp/VS_Snippets_ADO.NET/Classic WebData OdbcDataAdapter.OdbcDataAdapter1/CS/source.cs

View workflow job for this annotation

GitHub Actions / snippets-build

ERROR: Project missing. A project (and optionally a solution file) must be in this directory or one of the parent directories to validate and build this code.
using System.Data;
using System.Data.Odbc;

class Program
{
static void Main()
{
//string connectionString = "Driver={Microsoft Access Driver (*.mdb)};DBQ=C:\\Samples\\Northwind.mdb";
//string x = "DRIVER={SQL Server};SERVER=MyServer;Trusted_connection=yes;DATABASE=Northwind;"
}

//<Snippet1>
public static OdbcDataAdapter CreateDataAdapter(
OdbcConnection connection)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,9 @@
using System;

Check failure on line 1 in snippets/csharp/VS_Snippets_ADO.NET/Classic WebData OdbcDataAdapter.OdbcDataAdapter2/CS/source.cs

View workflow job for this annotation

GitHub Actions / snippets-build

ERROR: Project missing. A project (and optionally a solution file) must be in this directory or one of the parent directories to validate and build this code.
using System.Data;
using System.Data.Odbc;

class Program
{
static void Main()
{
//string connectionString = "Driver={Microsoft Access Driver (*.mdb)};DBQ=C:\\Samples\\Northwind.mdb";
//string x = "DRIVER={SQL Server};SERVER=MyServer;Trusted_connection=yes;DATABASE=Northwind;"
}

//<Snippet1>
public static OdbcDataAdapter CreateDataAdapter(
OdbcConnection connection)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,6 @@

class Program
{
static void Main()
{
//string connectionString = "Driver={Microsoft Access Driver (*.mdb)};DBQ=C:\\Samples\\Northwind.mdb";
//string x = "DRIVER={SQL Server};SERVER=MyServer;Trusted_connection=yes;DATABASE=Northwind;"
}

//<Snippet1>
public static OdbcDataAdapter CreateDataAdapter(
OdbcConnection connection)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,6 @@

class Program
{
static void Main()
{
//string connectionString = "Driver={Microsoft Access Driver (*.mdb)};DBQ=C:\\Samples\\Northwind.mdb";
//string x = "DRIVER={SQL Server};SERVER=MyServer;Trusted_connection=yes;DATABASE=Northwind;"
}

//<Snippet1>
public static OdbcDataAdapter CreateDataAdapter(
OdbcConnection connection)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,6 @@

class Program
{
static void Main()
{
//string connectionString = "Driver={Microsoft Access Driver (*.mdb)};DBQ=C:\\Samples\\Northwind.mdb";
//string x = "DRIVER={SQL Server};SERVER=MyServer;Trusted_connection=yes;DATABASE=Northwind;"
}

//<Snippet1>
public static OdbcDataAdapter CreateDataAdapter(
OdbcConnection connection)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,6 @@

class Program
{
static void Main()
{
//string connectionString = "Driver={Microsoft Access Driver (*.mdb)};DBQ=C:\\Samples\\Northwind.mdb";
}

// <Snippet1>
public DataSet GetDataSetFromAdapter(
DataSet dataSet, string connectionString, string queryString)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,6 @@

class Program
{
static void Main()
{
//string connectionString = "Driver={Microsoft Access Driver (*.mdb)};DBQ=C:\\Samples\\Northwind.mdb";
//string x = "DRIVER={SQL Server};SERVER=MyServer;Trusted_connection=yes;DATABASE=Northwind;"
}

// <Snippet1>
public DataSet GetDataSetFromAdapter(
DataSet dataSet, string connectionString, string queryString)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,7 @@ class Program
{
static void Main()
{
string connectionString = "Provider=sqloledb;Data Source=(local);Initial Catalog=Northwind;"
+ "Integrated Security=SSPI";
string connectionString = "Provider=sqloledb;Data Source=(local);Initial Catalog=Northwind;Integrated Security=SSPI";
string queryString = "UPDATE Shippers SET CompanyName = 'Speedy Expresss' WHERE ShipperID = 1";
CreateOleDbCommand(queryString, connectionString);
Console.ReadLine();
Expand Down
Loading