Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

activate task view programmatically windows 10

Is there a way to activate task view programmatically in windows 10?

There was a way to activate Flip3D programmatically in win7 using the following copied from VBScript SendKeys CTRL+LWIN+TAB?

CreateObject("WScript.Shell").Run "rundll32 DwmApi #105"

I just want to make a .vbs or .bat file that activates windows 10 Task View.

like image 951
blakedesign Avatar asked Sep 01 '25 17:09

blakedesign


2 Answers

OK Found a way to do it with C#

  1. Install Visual studio
  2. Install NuGet http://docs.nuget.org/consume/installing-nuget
  3. File > New Project
  4. Name it taskview
  5. Visual C# > Console application
  6. File > Save All
  7. Tools > NuGet Package Manager > Package Manager Console
  8. Type "Install-Package InputSimulator" in Package Manager console window
  9. Paste Following text in taskview.cs window

    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using System.Threading.Tasks;
    using WindowsInput.Native;// Importante
    
    namespace taskview
    {
        class Program
        {
            static void Main(string[] args)
            {
                WindowsInput.InputSimulator kb = new WindowsInput.InputSimulator();
                kb.Keyboard.ModifiedKeyStroke(VirtualKeyCode.LWIN, VirtualKeyCode.TAB);
                Console.Read();// Keep console window open
            }
        }
    }
    
  10. Change Dropdown with Debug in it to Release

  11. Build > Build Solution
  12. Build > Build taskview

It should be in: My Documents\Visual Studio 2015\Projects\taskview\taskview\bin\Release\taskview.exe

like image 160
blake.esq Avatar answered Sep 04 '25 13:09

blake.esq


Now tested on windows11 that command shell:::{3080F90E-D7AD-11D9-BD98-0000947B0257} can directly open Task View.

like image 29
PY-DNG Avatar answered Sep 04 '25 12:09

PY-DNG