-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
21 changed files
with
2,471 additions
and
16 deletions.
There are no files selected for viewing
119 changes: 119 additions & 0 deletions
119
InputHelper Library/InputHelper .NET 3.5/InputHelper .NET 3.5.vbproj
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,119 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | ||
<PropertyGroup> | ||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> | ||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform> | ||
<ProductVersion> | ||
</ProductVersion> | ||
<SchemaVersion> | ||
</SchemaVersion> | ||
<ProjectGuid>{8D0E884C-CE78-472F-916E-5CC64819FFC3}</ProjectGuid> | ||
<OutputType>Library</OutputType> | ||
<RootNamespace>InputHelperLib</RootNamespace> | ||
<AssemblyName>InputHelper .NET 3.5</AssemblyName> | ||
<FileAlignment>512</FileAlignment> | ||
<MyType>Windows</MyType> | ||
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion> | ||
<TargetFrameworkProfile /> | ||
</PropertyGroup> | ||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> | ||
<DebugSymbols>true</DebugSymbols> | ||
<DebugType>full</DebugType> | ||
<DefineDebug>true</DefineDebug> | ||
<DefineTrace>true</DefineTrace> | ||
<OutputPath>bin\Debug\</OutputPath> | ||
<DocumentationFile>InputHelper .NET 3.5.xml</DocumentationFile> | ||
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn> | ||
</PropertyGroup> | ||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' "> | ||
<DebugType>pdbonly</DebugType> | ||
<DefineDebug>false</DefineDebug> | ||
<DefineTrace>true</DefineTrace> | ||
<Optimize>true</Optimize> | ||
<OutputPath>bin\Release\</OutputPath> | ||
<DocumentationFile>InputHelper .NET 3.5.xml</DocumentationFile> | ||
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn> | ||
</PropertyGroup> | ||
<PropertyGroup> | ||
<OptionExplicit>On</OptionExplicit> | ||
</PropertyGroup> | ||
<PropertyGroup> | ||
<OptionCompare>Binary</OptionCompare> | ||
</PropertyGroup> | ||
<PropertyGroup> | ||
<OptionStrict>Off</OptionStrict> | ||
</PropertyGroup> | ||
<PropertyGroup> | ||
<OptionInfer>On</OptionInfer> | ||
</PropertyGroup> | ||
<ItemGroup> | ||
<Reference Include="System" /> | ||
<Reference Include="System.Data" /> | ||
<Reference Include="System.Drawing" /> | ||
<Reference Include="System.Windows.Forms" /> | ||
<Reference Include="System.Xml" /> | ||
<Reference Include="System.Core" /> | ||
<Reference Include="System.Xml.Linq" /> | ||
<Reference Include="System.Data.DataSetExtensions" /> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<Import Include="Microsoft.VisualBasic" /> | ||
<Import Include="System" /> | ||
<Import Include="System.Collections" /> | ||
<Import Include="System.Collections.Generic" /> | ||
<Import Include="System.Data" /> | ||
<Import Include="System.Diagnostics" /> | ||
<Import Include="System.Linq" /> | ||
<Import Include="System.Xml.Linq" /> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<Compile Include="InputHelper.vb" /> | ||
<Compile Include="My Project\AssemblyInfo.vb" /> | ||
<Compile Include="My Project\Application.Designer.vb"> | ||
<AutoGen>True</AutoGen> | ||
<DependentUpon>Application.myapp</DependentUpon> | ||
</Compile> | ||
<Compile Include="My Project\Resources.Designer.vb"> | ||
<AutoGen>True</AutoGen> | ||
<DesignTime>True</DesignTime> | ||
<DependentUpon>Resources.resx</DependentUpon> | ||
</Compile> | ||
<Compile Include="My Project\Settings.Designer.vb"> | ||
<AutoGen>True</AutoGen> | ||
<DependentUpon>Settings.settings</DependentUpon> | ||
<DesignTimeSharedInput>True</DesignTimeSharedInput> | ||
</Compile> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<EmbeddedResource Include="My Project\Resources.resx"> | ||
<Generator>VbMyResourcesResXFileCodeGenerator</Generator> | ||
<LastGenOutput>Resources.Designer.vb</LastGenOutput> | ||
<CustomToolNamespace>My.Resources</CustomToolNamespace> | ||
<SubType>Designer</SubType> | ||
</EmbeddedResource> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<None Include="My Project\Application.myapp"> | ||
<Generator>MyApplicationCodeGenerator</Generator> | ||
<LastGenOutput>Application.Designer.vb</LastGenOutput> | ||
</None> | ||
<None Include="My Project\Settings.settings"> | ||
<Generator>SettingsSingleFileGenerator</Generator> | ||
<CustomToolNamespace>My</CustomToolNamespace> | ||
<LastGenOutput>Settings.Designer.vb</LastGenOutput> | ||
</None> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<Content Include="LICENSE.txt"> | ||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> | ||
</Content> | ||
</ItemGroup> | ||
<Import Project="$(MSBuildToolsPath)\Microsoft.VisualBasic.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> |
Oops, something went wrong.
4935359
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi Vincent Bengtsson,
Your code is bright! I find everything except... how to combine tInputHelperLib.InputHelper.Keyboard.PressKey(System.Windows.Forms.Keys.Control AndAlso System.Windows.Forms.Keys.V)
in order to pass the "paste" command.
Could you help me?
Johan
4935359
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @jeedee23!
My sincere apologies for not seeing your comment earlier. I didn't get notified of it properly.
To simulate a key combination you have to use the
InputHelper.Keyboard.SetKeyState()
function for the modifier key so that you can control its state (down or up). This requires three lines of code:In the future please ask your questions over on the Issue tracker instead, that way I'm much more likely to see them (as well as other people). Thanks!