Added Full framework console sample.

This commit is contained in:
Eugene Wang
2018-11-14 06:04:35 -05:00
parent deff4dbae5
commit 593dd6e675
6 changed files with 114 additions and 3 deletions

View File

@@ -11,11 +11,13 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "common", "common", "{4CE0B9
twain-doc\twain2.4.h = twain-doc\twain2.4.h
EndProjectSection
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NTwain", "src\NTwain\NTwain.csproj", "{99A8D582-2CC1-479C-859D-C5A528A7B5C3}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NTwain", "src\NTwain\NTwain.csproj", "{99A8D582-2CC1-479C-859D-C5A528A7B5C3}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "samples", "samples", "{FC732BDB-39BD-4064-B6D8-B79E25CFDA4A}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NetCoreConsole", "samples\NetCoreConsole\NetCoreConsole.csproj", "{51EFA206-A46B-48B6-8110-67B07D85C5A2}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NetCoreConsole", "samples\NetCoreConsole\NetCoreConsole.csproj", "{51EFA206-A46B-48B6-8110-67B07D85C5A2}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NetFXConsole", "samples\NetFXConsole\NetFXConsole.csproj", "{30C684E3-7C3E-4579-9E81-6E66236C253D}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
@@ -31,12 +33,17 @@ Global
{51EFA206-A46B-48B6-8110-67B07D85C5A2}.Debug|Any CPU.Build.0 = Debug|Any CPU
{51EFA206-A46B-48B6-8110-67B07D85C5A2}.Release|Any CPU.ActiveCfg = Release|Any CPU
{51EFA206-A46B-48B6-8110-67B07D85C5A2}.Release|Any CPU.Build.0 = Release|Any CPU
{30C684E3-7C3E-4579-9E81-6E66236C253D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{30C684E3-7C3E-4579-9E81-6E66236C253D}.Debug|Any CPU.Build.0 = Debug|Any CPU
{30C684E3-7C3E-4579-9E81-6E66236C253D}.Release|Any CPU.ActiveCfg = Release|Any CPU
{30C684E3-7C3E-4579-9E81-6E66236C253D}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(NestedProjects) = preSolution
{51EFA206-A46B-48B6-8110-67B07D85C5A2} = {FC732BDB-39BD-4064-B6D8-B79E25CFDA4A}
{30C684E3-7C3E-4579-9E81-6E66236C253D} = {FC732BDB-39BD-4064-B6D8-B79E25CFDA4A}
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {7459323B-44F6-4E07-8574-E1B4B525086B}

View File

@@ -3,6 +3,7 @@
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>netcoreapp2.1</TargetFramework>
<RootNamespace>ConsoleApp</RootNamespace>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">

View File

@@ -2,7 +2,7 @@
using System;
using System.Reflection;
namespace NetCoreConsole
namespace ConsoleApp
{
class Program
{
@@ -62,6 +62,7 @@ namespace NetCoreConsole
Console.WriteLine("ERROR: " + ex.ToString());
}
Console.WriteLine("----------------------------------");
Console.WriteLine("Test ended, press Enter to exit...");
Console.ReadLine();
}

View File

@@ -0,0 +1,6 @@
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5" />
</startup>
</configuration>

View File

@@ -0,0 +1,60 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{30C684E3-7C3E-4579-9E81-6E66236C253D}</ProjectGuid>
<OutputType>Exe</OutputType>
<RootNamespace>ConsoleApp</RootNamespace>
<AssemblyName>NetFXConsole</AssemblyName>
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<Deterministic>true</Deterministic>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
<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' ">
<PlatformTarget>AnyCPU</PlatformTarget>
<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" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="Microsoft.CSharp" />
<Reference Include="System.Data" />
<Reference Include="System.Net.Http" />
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="..\NetCoreConsole\Program.cs">
<Link>Program.cs</Link>
</Compile>
<Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup>
<ItemGroup>
<None Include="App.config" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\..\src\NTwain\NTwain.csproj">
<Project>{99a8d582-2cc1-479c-859d-c5a528a7b5c3}</Project>
<Name>NTwain</Name>
</ProjectReference>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
</Project>

View File

@@ -0,0 +1,36 @@
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("NetFXConsole")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("NetFXConsole")]
[assembly: AssemblyCopyright("Copyright © 2018")]
[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("30c684e3-7c3e-4579-9e81-6e66236c253d")]
// 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")]