diff --git a/D365FONinjaDevTools/D365FoNinjaDevExtensionsPackage.vsct b/D365FONinjaDevTools/D365FoNinjaDevExtensionsPackage.vsct index 350aa82..7aeb9bb 100644 --- a/D365FONinjaDevTools/D365FoNinjaDevExtensionsPackage.vsct +++ b/D365FONinjaDevTools/D365FoNinjaDevExtensionsPackage.vsct @@ -17,7 +17,7 @@ - + @@ -40,11 +40,11 @@ Extend... - @@ -52,7 +52,7 @@ - + @@ -61,6 +61,13 @@ editor="guidVSStd97" key1="VK_ADD" mod1="Control"> + + + + @@ -71,6 +78,8 @@ + + @@ -83,18 +92,7 @@ - - - - - - - - - - - - + \ No newline at end of file diff --git a/D365FONinjaDevTools/NewFolder1/Command1.cs b/D365FONinjaDevTools/NewFolder1/Command1.cs index a2be3be..0643874 100644 --- a/D365FONinjaDevTools/NewFolder1/Command1.cs +++ b/D365FONinjaDevTools/NewFolder1/Command1.cs @@ -1,5 +1,6 @@ using System; using System.ComponentModel.Design; +using D365FONinjaDevTools.Kernel; using Microsoft.VisualStudio.Shell; namespace D365FONinjaDevTools.NewFolder1 @@ -12,12 +13,12 @@ internal sealed class Command1 /// /// Command ID. /// - public const int CommandId = 0x1025; + public const int CommandId = 1025; /// /// Command menu group (command set GUID). /// - public static readonly Guid CommandSet = new Guid("2db687bb-05d6-4c38-94db-a56751bcf34b"); + public static readonly Guid CommandSet = new Guid("5ed27ab2-7007-4c3d-a535-88720e97b49f"); /// /// VS Package that provides this command, not null. @@ -39,9 +40,12 @@ private Command1(Package package) OleMenuCommandService commandService = this.ServiceProvider.GetService(typeof(IMenuCommandService)) as OleMenuCommandService; if (commandService != null) { + var menuCommandID = new CommandID(CommandSet, CommandId); var menuItem = new MenuCommand(this.MenuItemCallback, menuCommandID); commandService.AddCommand(menuItem); + + menuItem.Visible = true; } } @@ -77,7 +81,9 @@ public static void Initialize(Package package) /// Event args. private void MenuItemCallback(object sender, EventArgs e) { - + LocalUtils.MyDte.ExecuteCommand("Edit.SelectAll"); + LocalUtils.MyDte.ExecuteCommand("Edit.Copy"); + LocalUtils.MyDte.ExecuteCommand("Edit.Paste"); } } } diff --git a/D3FONinjaDevTools.sln b/D3FONinjaDevTools.sln index e71bcce..4cb651e 100644 --- a/D3FONinjaDevTools.sln +++ b/D3FONinjaDevTools.sln @@ -7,8 +7,6 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "D365FONinjaDevTools", "D365 EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "D365FONinjaDevTools_Setup", "D365FONinjaDevToolsSetup\D365FONinjaDevTools_Setup.csproj", "{40EC3306-FD6A-4973-A9F5-6D50867D3ACE}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WpfApplication1", "WpfApplication1\WpfApplication1.csproj", "{554AC5FB-4EC5-4188-AE38-6946BA6AC019}" -EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU @@ -23,10 +21,6 @@ Global {40EC3306-FD6A-4973-A9F5-6D50867D3ACE}.Debug|Any CPU.Build.0 = Debug|Any CPU {40EC3306-FD6A-4973-A9F5-6D50867D3ACE}.Release|Any CPU.ActiveCfg = Release|Any CPU {40EC3306-FD6A-4973-A9F5-6D50867D3ACE}.Release|Any CPU.Build.0 = Release|Any CPU - {554AC5FB-4EC5-4188-AE38-6946BA6AC019}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {554AC5FB-4EC5-4188-AE38-6946BA6AC019}.Debug|Any CPU.Build.0 = Debug|Any CPU - {554AC5FB-4EC5-4188-AE38-6946BA6AC019}.Release|Any CPU.ActiveCfg = Release|Any CPU - {554AC5FB-4EC5-4188-AE38-6946BA6AC019}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE