How to recreate “Show Desktop” when all of a sudden it’s nowhere to be found!

It might be a liitle weird to post this here but believe me, it has happened to me before and I thought this might help someone.

Follow these steps to recreate “Show Desktop” shortcut on your Windows Quick Launch:

1. Click Start

2. Click Run

3. Type in “notepad”

4. Click “OK”

5. Copy and paste the follwing text inside the notepad document:

[Shell]
Command=2
IconFile=explorer.exe,3
[Taskbar]
Command=ToggleDesktop

6. Save the file as ShowDesktop.scf in C:\Dokument and Settings\%username%\Appdata\Microsoft\Internet Explorer\Quick Launch

When finished, it lokks like this:


Posted in Vista, Windows, Windows 7, Windows Vista, Windows XP and tagged , , by with comments disabled.

How To Use SCHTASKS

Create, delete, edit, list, start or stop a scheduled task.
Works on local or remote computers.
Syntax:

SCHTASKS /Create [Connect_Options] create_options

SCHTASKS /Delete [Connect_Options] /TN taskname [/F]

SCHTASKS /Query [Connect_Options] [/FO format] [/NH] [/V]

SCHTASKS /Run [Connect_Options] /TN taskname
SCHTASKS /End [Connect_Options] /TN taskname

SCHTASKS /Change [Connect_Options] {[/RU username] [/RP password] [/TR taskrun]} /TN taskname

Connect_Options:
/S system #remote system (default is local)
[/U username [/P password]] #submit job under this name

create_options:
[/RU username [/RP password]] #run job under this name
/SC schedule [/MO modifier] #When to run, see below
[/D day] #day = MON,TUE,WED,THU,FRI,SAT,SUN
[/M months] #month=JAN,FEB,MAR,APR,MAY,JUN,JUL,AUG,SEP,OCT,NOV,DEC.
[/I idletime] #1 – 999 minutes (ONIDLE task only)
/TN taskname /TR taskrun #Name and pathname for task
/ST starttime #HH:MM:SS (24 hour)
[/SD startdate] [/ED enddate] #start and end date “dd/mm/yyyy”

options:
/F Force delete, ignore warnings even if the task is currently runnning.
/FO format Output format: TABLE, LIST, CSV
/NH No header
/V Verbose output
Notes:
For MONTHLY schedules give the DAY as a number 1 – 31 (default=1)

To prompt for the password, specify /RP * or /RP none
The User Account under which the Schedule service runs may require specific file access permissions, user permissions and drive mappings.
If the /RU username and /RP Password parameters match the currently logged-in user, the task will run interactively (visible in the foreground).

For the system account, /RU username can be written as “”, “NT AUTHORITY\SYSTEM” or “SYSTEM”, a Password is not required. The system account has full access to the local machine but has no permissions on any other machines (or mapped drives) across the Network.
/SC schedule The schedule frequency.
Valid schedules: MINUTE,HOURLY,DAILY,WEEKLY,MONTHLY, ONCE,ONSTART,ONLOGON,ONIDLE.

/MO modifiers allow finer control:

MINUTE: 1 – 1439 minutes.
HOURLY: 1 – 23 hours.
DAILY: 1 – 365 days.
WEEKLY: 1 – 52 weeks.
ONCE: No modifiers.
ONSTART: No modifiers.
ONLOGON: No modifiers.
ONIDLE: No modifiers.
MONTHLY: 1 – 12, or FIRST, SECOND, THIRD, FOURTH, LAST, LASTDAY.
Power Saving
The property for “Wake up the machine to run this task” cannot be set using schtasks, but this property is essential if you need the task to run on a machine that has PowerSaving enabled.
To work around this, create a task on one computer using the control panel GUI. This will create a .job file in C:\%windir%\Tasks\
To replicate the scheduled task onto other machines copy the .JOB file to C:\%windir%\Tasks on each machine.

This techique will not retain any system account credentials, so if you need to run the tasks under System, run the following after copying the .JOB file:
SCHTASKS /CHANGE /RU “NT Authority\System” /TN “Yourtaskname”
Examples:
Create a task to run at 11 pm every weekday
SCHTASKS /Create /SC weekly /D MON,TUE,WED,THU,FRI /TN MyDailyBackup /ST 23:00:00 /TR c:\backup.cmd /RU MyDomain\MyLogin /RP MyPassword
Now delete the task:
SCHTASKS /Delete /TN “MyDailyBackup” /f
Create a daily task to run a script at 5 pm:
SCHTASKS /create /tn “My Script” /tr “\”c:\my folder\script.cmd\” arguments” /sc daily /sd 12/29/2008 /st 17:00
Task Scheduler options are stored in the registry
HKLM\SOFTWARE\Microsoft\SchedulingAgent\


Posted in Vista, Windows, Windows 7, Windows Vista, Windows XP and tagged , by with 1 comment.

Here is how to activate Windows manually

We will be using the commandd line to start the activation program.

Windows (XP/Vista/7/2003/2008) will normally remind users to activate their product soon after installation. To activate Windows manually, you can use the Start menu shortcut in the System Tools Accessories folder. At the command prompt, type

oobe/msoobe /a

In case you’re wondering, msoobe stands for “Microsoft Out of Box Experience.”


Posted in Vista, Windows, Windows 7, Windows Vista, Windows XP and tagged , by with 4 comments.

How to use rsync with progressbar

It becomes very frustrating when copying large files with “cp” because of the lack of progressbar. With “rsync” in contrast, you can toggle verbose mode with ‘-v’ to enable feedback through the progressbar. So when copying several files, you will be able to know which files are done. Unfortunately, there’s no single-file progress to be seen.

Using rsync, you can. And it’s available on nearly every linux release, too.

Here’s the syntax difference:

cp <oldfile> <newfile>
rsync --progress <oldfile> <newfile>

rsync would then look like this:

It gives you an estimated time remaining, as well as a speed indication. And it shouldn’t affect your total copy time by that much, either.

For more details on parameters and syntax, click here


Posted in Vista, Windows, Windows 7, Windows Vista and tagged , , by with comments disabled.

How to update Group Policy without restarting your Windows server

After you modify group policies, you may wish that these changes are applied immediately, without waiting for the default update interval (90 minutes on domain members and 5 minutes on domain controllers), or having to restart the computer.

Run gpupdate /force at the command prompt, to update the Group Policy without restarting the domain controller. The “Gpupdate.exe” program can also be used with the following parameters as described bellow:

Syntax:

GPUpdate [/ target: (computer | user)] [/ Force] [/ Wait: value] [/ Logoff] [/ Boot]

Options

/ Target: (computer | user)
You can use this option if you want to specify that only updated user or computer policies. If you do not use this option, by default, both user and computer policy updated.

/ Force
This option reapplies all policy settings. By default, only the policy settings that were changed.

/ Wait: (value)
With this option you can specify how many seconds you have to wait until the processing of all the guidelines are finalized. The default is 600 seconds. You do not have to wait, if you set the value to zero (0). If you set the value to -1, you have to wait indefinitely. When the time limit is reached, returns to the command prompt, but will continue processing the directives.

/ Logoff
This option means that your session is logged off the computer after the Group Policy has been updated. This behavior is for those Group Policy client computer extensions need not update the guidelines periodically in the background, however, process the policy when a user logs on the computer. Two examples of such behavior can include features for the user-specific software installation and to monitor the folder redirection. This option has no effect if extensions have not been called that require you to log off the computer.

/ Boot
This option can force a restart of your computer after the Group Policy settings have been updated. This behavior is for those Group Policy client computer extensions need not update the guidelines periodically in the background, however, process the guidelines when you restart the computer. An example of this behavior is observed in the feature for the user-specific software. This option has no effect if extensions have not been called that require a reboot of your computer.


Posted in Vista, Windows, Windows 7, Windows Vista, Windows XP and tagged , by with comments disabled.

The display on my monitor has rotated 90 degrees clockwise. How can I rotate my display back to normal?


Office emergency! Help me get this monitor out of portrait mode and back into its usual landscape display!

Best Case Scenario

A secretary put a heavy folder full of papers down on her keyboard without looking. Apparently, she hit some mysterious key combination that rotated the entire display 90 degrees clockwise. Evidently the mysterious key combination was “Control-Alt-Right Arrow.”

Solution:

Actually this is very simple – Windows XP has integrated controls for rotating the view.

Simply hold the Control-Alt-Down (Ctrl+Alt+Down) to rotate the display 90 degrees back to normal


Posted in Vista, Windows, Windows 7, Windows Vista, Windows XP and tagged , , , , , by with comments disabled.

Windows Routing Command

Route

Displays and modifies the entries in the local IP routing table. Used without parameters, route displays help.

Syntax

route [-f] [-p] [Command [Destination] [mask Netmask] [Gateway] [metric Metric]] [if Interface]]

Parameters

-f : Clears the routing table of all entries that are not host routes (routes with a netmask of 255.255.255.255), the loopback network route (routes with a destination of 127.0.0.0 and a netmask of 255.0.0.0), or a multicast route (routes with a destination of 224.0.0.0 and a netmask of 240.0.0.0). If this is used in conjunction with one of the commands (such as add, change, or delete), the table is cleared prior to running the command.

-p : When used with the add command, the specified route is added to the registry and is used to initialize the IP routing table whenever the TCP/IP protocol is started. By default, added routes are not preserved when the TCP/IP protocol is started. When used with the print command, the list of persistent routes is displayed. This parameter is ignored for all other commands. Persistent routes are stored in the registry location

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters\PersistentRoutes.

Examples

To display the entire contents of the IP routing table, type:

route print

To display the routes in the IP routing table that begin with 10., type:

route print 10.*

To add a default route with the default gateway address of 192.168.12.1, type:

route add 0.0.0.0 mask 0.0.0.0 192.168.12.1

To add a route to the destination 10.41.0.0 with the subnet mask of 255.255.0.0 and the next hop address of 10.27.0.1, type:

route add 10.41.0.0 mask 255.255.0.0 10.27.0.1

To add a persistent route to the destination 10.41.0.0 with the subnet mask of 255.255.0.0 and the next hop address of 10.27.0.1, type:

route -p add 10.41.0.0 mask 255.255.0.0 10.27.0.1

To add a route to the destination 10.41.0.0 with the subnet mask of 255.255.0.0, the next hop address of 10.27.0.1, and the cost metric of 7, type:

route add 10.41.0.0 mask 255.255.0.0 10.27.0.1 metric 7

To add a route to the destination 10.41.0.0 with the subnet mask of 255.255.0.0, the next hop address of 10.27.0.1, and using the interface index 0x3, type:

route add 10.41.0.0 mask 255.255.0.0 10.27.0.1 if 0x3

To delete the route to the destination 10.41.0.0 with the subnet mask of 255.255.0.0, type:

route delete 10.41.0.0 mask 255.255.0.0

To delete all routes in the IP routing table that begin with 10., type:

route delete 10.*

To change the next hop address of the route with the destination of 10.41.0.0 and the subnet mask of 255.255.0.0 from 10.27.0.1 to 10.27.0.25, type:

route change 10.41.0.0 mask 255.255.0.0 10.27.0.25


Posted in Networking, Vista, Windows, Windows 7, Windows Vista, Windows XP and tagged , , , by with comments disabled.

Autorun Apps from your USB Drive

Just like there is autoplay feature on CDs and DVDs, it is also possible to autorun programs and applications from your removable USB flash drives on Windows XP SP2.

The follwoing is a quick guide on how to autorun portables applications from your USB drive.

  1. Open Notepad
  2. Type in:

      [AutoRun]
      open=PortableApps\PortableAppsMenu\PortableAppsMenu.exe
      action=Start PortableApps.com
      icon=PortableApps\PortableAppsMenu\PortableAppsMenu.exe
      label=PortableApps
      Shell\Option=PortableApps
      Shell\Option\Command=PortableApps\PortableAppsMenu\PortableAppsMenu.exe

  3. Save the files as autorun.inf
  4. Put the files in the root of your USB flash drive
  5. The next time you insert your flash USB drive into any PC running Windows XP SP2, the specified program will autorun from the USB drive.

Below are the explanations to the above options used in our autorun.inf file.

  open=PortableApps\PortableAppsMenu\PortableAppsMenu.exe

The open option specifies the program that should autorun. You must use relative paths here. Do NOT specify the drive letter since it may vary from PC to PC.

  action=Start PortableApps.com

This describes the action that will be performed. This parameter is used by Windows Explorer in the autoplay dialog.

  icon=PortableApps\PortableAppsMenu\PortableAppsMenu.exe

Specifies the icon to be used for the USB drive. The icon can be fetched from an .EXE file or it can be in the normal .ICO format. More on changing icons here

  label=PortableApps

This label parameter is used to specify the name of the drive. Basically, this can be anything you want to call your flash drive.

  Shell\Option=PortableApps

Optionally specify the text displayed in the shortcut menu for the Option above.

  Shell\Option\Command=PortableApps\PortableAppsMenu\PortableAppsMenu.exe

Adds a custom command to the drive’s shortcut menu. This is also the text that will appear in the shortcut menu unless specifically altered to some other text.

In many systems, the autorun is disabled by default for security reasons. Unless it is very neccessary, you are adviced to keep the default settings. Why this might be true for many users, there are those like me who would rather have the autorun enabled to ease working with PortableApps.

If your Autorun is disabled, go here to learn how to enable it.


Posted in Vista, Windows, Windows 7, Windows Vista, Windows XP and tagged , , , , , by with comments disabled.