Wednesday, July 12, 2017

Repair hard-drive errors

Select the Start  button, then in the search box on the taskbar, type command prompt. Choose Command Promptfrom the list of results. In the window that pops up, type chkdsk/f C: and press the Enter key. Repairs automatically start on your hard drive, and you’ll be asked to restart your device.

Friday, May 6, 2016

How to Create, Modify and Delete Scheduled Tasks from the Command Line

Examples

Create ‘My Task’ to run C:RunMe.bat at 9 AM everyday:

SchTasks /Create /SC DAILY /TN “My Task” /TR “C:RunMe.bat” /ST 09:00
image
image

Modify ‘My Task’ to run at 2 PM:

SchTasks /Change /TN “My Task” /ST 14:00
image
image 

Create ‘My Task’ to run C:RunMe.bat on the first of every month:

SchTasks /Create /SC MONTHLY /D 1 /TN “My Task” /TR “C:RunMe.bat” /ST 14:00
image
image

Create ‘My Task’ to run C:RunMe.bat every weekday at 2 PM:

SchTasks /Create /SC WEEKLY /D MON,TUE,WED,THU,FRI /TN “My Task” /TR “C:RunMe.bat” /ST 14:00
image
image

Delete the task named ‘My Task’:

SchTasks /Delete /TN “My Task”
image
Note: this will raise a warning which you will need to confirm.

Bulk Creation

Like any other command line tool, you can include multiple instructions in a batch file to accomplish bulk creation (or deletion).
For example, this script:
SchTasks /Create /SC DAILY /TN “Backup Data” /TR “C:Backup.bat” /ST 07:00
SchTasks /Create /SC WEEKLY /D MON /TN “Generate TPS Reports” /TR “C:GenerateTPS.bat” /ST 09:00
SchTasks /Create /SC MONTHLY /D 1 /TN “Sync Database” /TR “C:SyncDB.bat” /ST 05:00
Produces these tasks:
image
The ability to do this is a quick way to roll out new tasks or change existing schedules to many machines at once. As a way to ensure the tasks are updated, you could include the appropriate SchTasks commands in a domain login script which will update user machines when they log in.
Source: http://www.howtogeek.com/51236/how-to-create-modify-and-delete-scheduled-tasks-from-the-command-line/

Saturday, January 30, 2016

Manually uninstall Office 2016 or Office 365

NOTE   Before you start, you need to know removing Office manually is a long, complex process and might require that you reinstall the operating system if certain steps are done incorrectly.
You'll need to determine your Office installation type so you can choose the correct way to uninstall it:
  • Click-to-Run is a new way to install and update Office over the Internet and it works similar to streaming video. By default, Office 365, including Office 2016 products are installed by using Click-to-Run.
  • MSI, (also known as the Microsoft Windows Installer), is the traditional way of installing Office via a local installation resource.
    To determine your installation type
    1. Start an Office application, like Word.
    2. Click File > Account.
    3. If Office 2016 was installed using Click-to-Run, an Update Options appears. For an MSI installation, theUpdate Options are installed through Windows Update only.

Manually remove a Click-to-Run installation of Office

Before you begin, make sure that you log on to Windows with an administrator account. If you’re not sure if you have an administrator account, see how to determine your user account type in Windows.
Step 1: Remove the Windows Installer packages
  1. Find the Office 16 installation folder, typically located in C:\Program Files\.
  2. Right-click the Microsoft Office 16 folder and select Delete.
Step 2: Remove the Office scheduled tasks
  1. Open a Command Prompt window as an administrator.
  2. At the command prompt, type the following commands and press Enter after each one:
    schtasks.exe /delete /tn "\Microsoft\Office\Office Automatic Updates"
    schtasks.exe /delete /tn "\Microsoft\Office\Office Subscription Maintenance"
    schtasks.exe /delete /tn "\Microsoft\Office\Office ClickToRun Service Monitor"
    schtasks.exe /delete /tn "\Microsoft\Office\OfficeTelemetryAgentLogOn2016"
    schtasks.exe /delete /tn "\Microsoft\Office\OfficeTelemetryAgentFallBack2016"
Step 3: Use Task Manager to end the Click-to-Run tasks
  1. Open Task Manager.
    • Windows 10: Right-click Start, and click Task Manager. (The keyboard shortcut Windows logo key + X also works to open the access menu.)
    • Windows 8 or 8.1: Point to the upper-right corner of the screen, move the mouse pointer down, and then click Search. Type Task Manager in the search box, and then click Task Manager in the results.
    • Windows 7: Right-click an empty area of the taskbar, and then click Start Task Manager.
  2. Click the Process tab.
  3. If the following processes are running, right-click each one, and then click End task in Windows 10, End Taskin Windows 8 or 8.1, or End Process in Windows 7 after you select each process.
    • OfficeClickToRun.exe
    • OfficeC2RClient.exe
    • AppVShNotify.exe
    • setup*.exe
Step 4: Delete the Office service
  • Open a Command Prompt window as an administrator, type the following command, and then press Enter:
    sc delete ClickToRunSvc
Step 5: Delete the Office files
  1. Press Windows logo key + R to open the Run dialog box.
  2. In the Open box, type %ProgramFiles%, and then click OK.
  3. Delete the "Microsoft Office 16" folder.
  4. Delete the “Microsoft Office” folder.
  5. Open the Run dialog box, type %ProgramFiles(x86)%, and then click OK.
  6. Delete the “Microsoft Office” folder.
  7. Open the Run dialog box, type %CommonProgramFiles%\Microsoft Shared and then click OK.
  8. Delete the “ClickToRun” folder.
  9. Open the Run dialog box, type %ProgramData%\Microsoft, and then click OK.
  10. Delete the ClickToRun folder. If the folder does not exist, go to the next step.
  11. Open the Run dialog box, type %ProgramData%\Microsoft\Office, and then click OK.
  12. Delete the ClickToRunPackagerLocker file.
    NOTE   If you can't delete a folder or a file that's open or that's being used by another program, restart the computer, and then try again. If you still can't remove the folder, go to the next step.
IMPORTANT   Follow the steps in this section carefully. Serious problems may occur if you modify the registry incorrectly. Before you start, back up the registry for restoration in case problems occur.
Step 6: Delete the Office registry subkeys
  1. Open Registry Editor.
    • Windows 10: Right-click Start, click Run, type regedit, and then click OK.
    • Windows 8 or 8.1: Right-click Start, click Run, type regedit, and then click OK.
    • Windows 7: Click Start, type Run in the Start Search box, and then click Run in the results.
  2. Delete the following registry subkeys:
    • HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office\ClickToRun
    • HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\AppVISV
    • HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\Microsoft Office <Edition> - en-us
    • HKEY_CURRENT_USER\Software\Microsoft\Office
    • Then Delete the Office key.
      NOTE   In the subkey in the third bullet item, "Microsoft Office <Edition>- en-us" represents the actual program name. This name depends on the Office 2016 edition and language version that you installed.
Step 7: Delete the Start menu shortcuts
  1. Open a Command Prompt window as an administrator.
  2. Type %ALLUSERSPROFILE%\Microsoft\Windows\Start Menu\Programs, and then press Enter.
  3. Delete the “Microsoft Office 2016 Tools” folder.
  4. Delete each of the “<application> 2016” shortcuts for each of the Office 2016 applications. For example, “Word 2016”, “Excel 2016”, “PowerPoint 2016”.
Step 8: Uninstall the Office 16 Click-To-Run Licensing Component, Extensibility Component and Localization Component
  1. Open a Command Prompt window as an administrator.
  2. At the command prompt, type the command that is appropriate for your operating system, and then press Enter:
    • If you're running an x86 version of Office 2016 on an x64 operating system, run the following commands:
      MsiExec.exe /X{90160000-008F-0000-1000-0000000FF1CE}
      MsiExec.exe /X{90160000-008C-0000-0000-0000000FF1CE}
      MsiExec.exe /X{90160000-008C-0409-0000-0000000FF1CE}
    • If you're running an x86 version of Office 2016 on an x86 operating system, run the following command:
      MsiExec.exe /X{90160000-007E-0000-0000-0000000FF1CE}
      MsiExec.exe /X{90160000-008C-0000-0000-0000000FF1CE}
      MsiExec.exe /X{90160000-008C-0409-0000-0000000FF1CE}
    • If you're running an x64 version of Office 2016 on an x64 operating system, run the following command:
      MsiExec.exe /X{90160000-007E-0000-1000-0000000FF1CE}
      MsiExec.exe /X{90160000-008C-0000-1000-0000000FF1CE}
      MsiExec.exe /X{90160000-008C-0409-1000-0000000FF1CE}
Source: https://support.office.com/en-us/article/Manually-uninstall-Office-2016-or-Office-365-4e2904ea-25c8-4544-99ee-17696bb3027b?ui=en-US&rs=en-US&ad=US

Friday, January 8, 2016

What is the Difference Between Log Off, Restart, and Shut Down?

To shut down (or power down, or power off) a system means that, when the process of shutting down is complete, the machine is powered down, and it will not come back up again without a someone taking further action, e.g., powering it back on again. If you expect your system will be needed for maintenance or remote access by someone else, shutting it down effectively prevents this.
To power on a system means that you simply press the power button and let the system come up to a login prompt.
If you enter your username and password, you have gone a step further and have logged on.



To restart (or reboot) a system means that the computer goes through a complete shutdown process, then starts back up again. This is frequently required after software installations or during troubleshooting.



To log off or Sign out a system means that the user who is currently logged on has their session end, but leaves the computer running for someone else to use. This is faster than a full restart and, generally, a better choice during the course of the business day when a system is shared between multiple users.




To Switch account means you will be leaving current user behind (not logged out) and attempt to login using your credentials. this will take lot of memory from the computer RAM. as a result computer will be very slow. also this will prevent others using the same documents opened in other users. so the best way is to sign out from the user before login to another.



Thursday, October 15, 2015

How To Uninstall Your Windows Product Key

image
Do you have an old PC you want to sell, but also want to use your Windows license on your new PC ? There is a hidden command in Windows that allows you to do just that. Read on to find out more.
Note: Between Microsoft and your OEM there are a number of different laws that determine whether you are allowed to use your license on another PC, so follow this tutorial at your own risk. Additionally before you go through the tutorial you will want to check that your product key is still attached to your PC/Installation CD, if it is not , do a quick Google search on how to recover it.

Uninstalling Your Product Key

The first thing we need to do is get our activation ID, to do this fire up an administrative command prompt and run:
slmgr /dlv
image
Windows will open a message box and tell you a bunch of information about the license status of your PC, take note of your activation ID.
image
To uninstall your product key you need to use the /upk switch, along with your activation ID:
slmgr /upk 507660dd-3fc4-4df2-81f5b559467ad56b
image
If you do it correctly you will be told that your product key has been uninstalled.
image

Installing Your Product Key

Installing your product key on your new PC is just as easy, all you need to do is fire up an administrative command prompt and use the /ipk switch.
image
If your key is valid you will be told that your key was installed.
image
That’s all there is to it..
Source: www.howtogeek.com/124286/how-to-uninstall-your-windows-product-key-before-you-sell-your-pc/