Windows 10: Extending the Functions of Windows 10ís Cortana

  1. Posts : 5
    Windows 10 64-bit
       13 Aug 2015 #1

    Extending the Functions of Windows 10ís Cortana

    Cortana is quite capable, but there are times when I wish it has more features. For example, I really wanted to be able to lock my computer with a single voice command, but Cortana does not have this function built in. Fortunately, it is possible to extend Cortana's function. To do so, we make use of the fact that Cortana searches through the start menu shortcuts when you say the keyword "open" or "launch".

    Here are the steps to create a command to lock your computer:

    1. Create a shortcut in an accessible location such as the desktop. This can be achieved by pressing the right mouse button and select [New]->[Shortcut].
    2. For the location of the item, enter: %SystemRoot%\System32\rundll32.exe user32.dll,LockWorkStation
    3. Give the shortcut a natural name, which is what Cortana will look for when you speak to her. Since Cortana utilitizes natural language processing, it is much better at recognizing phrases that actually make sense.
    4. Copy the newly created shortcut to: %SystemDrive%\ProgramData\Microsoft\Windows\Start Menu\Programs. You will need administrative privileges to complete this step.

    If all goes well, you should be able to lock your computer by saying "hey Cortana, open lock computer".

    You can create similar commands to hibernate or sleep your computer. Just change the location of the item accordingly:

    • Hibernate: %SystemRoot%\System32\rundll32.exe Powrprof.dll,SetSuspendState Sleep
    • Sleep: You need PSTools from Microsoft. Set item location as: [Location of PSTools]\psshutdown.exe -d -t 0

    Another thing you can do is to create a command to open a website. You might think that this would be as simple as adding an internet shortcut to the start menu, but turns out it is more complicated than that: while Cortana keeps a record of internet shortcuts created through installation of programs, she does not do so with ones that are added manually. Furthermore, she does not index shortcuts that have non-executable extensions, meaning that you cannot use "chrome.exe", because this would be recognized as having a ".com" extension.

    Here is how to get around this issue:

    1. Create a text file and type in it "start " followed by the URL you want to open.
    2. Change the extension of the text file to ".bat"
    3. Create a shortcut that points to the file you just created and follow the aforementioned steps.

    For example, I have created a shortcut called "Gmail" that points to a "Gmail.bat" that executes "start". With this, Cortana would open Gmail with my computer's default browser when I say "Hey Cortana, open Gmail".

    Upon creating the shortcuts, you might notice that the default icon is quite uninformative. You can pick a better one after you created the shortcut by right-clicking on the icon, click [Properties], followed by clicking [Change Icon...]. Enter one of the following in "Look for icons in this file" textbox, where you should find a lot of icons to choose from:

    So here you go, try it out!

      My ComputerSystem Spec

  2.    21 Aug 2015 #2

    Thank you for the post. I have added gmail and facebook to the commands that Cortana can understand. I was looking for ways to programatically extend Cortana when I saw your post come up in the search results. This is by far the easiest way to add simple commands to open foreground applications. Thanks again!
      My ComputerSystem Spec


Related Threads
hello i have VAIO E VPCEH3AEA Fn + F1 = lock touchpad =>not working Fn + F2 = mute volume => working Fn + F3 = decrease volume => working Fn + F4 = increase volume => working Fn + F5 = decrease brightness => not working Fn + F6 = increase...
My Windows 10 is having major problems. So many that I would rather just remove the entire thing. I found a website that said you can revert to your previous OS in settings, but my problem is I cannot even get there. The entire task bar and start...
When I start up my computer, it seems to load up perfectly fine but when I go on teamspeak or other apps, problems begin. I have the turtlebeach px5 which requires a bluetooth adapter to work but when I go on teamspeak. My microphone does not seem...
I thought Microsoft's explanation of why they dropped DVD support from the Windows 8 - Media Player (because everyone streamed movies now days) was a little silly. Umm, but I wonder about all those millions upon millions of dvd's still out there...
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd
All times are GMT -5. The time now is 11:08.
Find Us