Change MAC address

1. Go to Start->Settings->Control Panel and double click on Network and Dial-up Connections.

2. Right click on the NIC you want to change the MAC address and click on properties.

3. Under “General” tab, click on the “Configure” button

4. Click on “Advanced” tab

5. Under “Property section”, you should see an item called “Network Address” or “Locally Administered Address”, click on it.

6. On the right side, under “Value”, type in the New MAC address you want to assign to your NIC. Usually this value is entered with the “-“ between the MAC address numbers.

7.Goto command prompt and type in “ipconfig /all” or to verify the changes. If the changes are not materialized, then use the second method.


Google gears-Access the web offline!

Gears, formerly Google Gears, is beta software offered by Google to enable offline access to services that normally only are available online. It installs a database engine, based on SQLite, on the client system to cache the data locally. Gears-enabled pages use data from this local cache rather than from the online service. Using Gears, a web application may periodically synchronize the data in the local cache with the online service. If a network connection is not available, the synchronization is deferred until a network connection is established. Thus Gears enables web applications to work even though access to the network service is not present.

Server Log

A server log is a log file (or several files) automatically created and maintained by a server of activity performed by it.

A typical example is a web server log which maintains a history of page requests. The W3C maintains a standard format[1] for web server log files, but other proprietary formats exist. More recent entries are typically appended to the end of the file. Information about the request, including client IP address, request date/time, page requested, HTTP code, bytes served, user agent, and referer are typically added. These data can be combined into a single file, or separated into distinct logs, such as an access log, error log, or referer log. However, server logs typically do not collect user-specific information.

These files are usually not accessible to general Internet users, only to the webmaster or other administrative person. A statistical analysis of the server log may be used to examine traffic patterns by time of day, day of week, referrer, or user agent. Efficient web site administration, adequate hosting resources and the fine tuning of sales efforts can be aided by analysis of the web server logs. Marketing departments of any organization that owns a website should be trained to understand these powerful tools.

Something about batch programming

The simplest idea of how to write a batch file is: Figure out how you would type the commands at a DOS prompt, then type them, one per line, in a text file — and you’ve written your batch file.

Commandline Arguements {%x}

Variables can be inserted into a batch structure in the form of command line arguements. These are in the form %1, %2, etc. To populate the variables, type the desired values after the batch file name when executing it.

DOS Environment Variable Names {%nn%}

DOS environment variables also can be used as variables in batch files. For example:

COPY %windir%\filename a:

Where does one get a list of DOS environment variables? I have never found a comprehensive list; but a partial but lengthy list of existing environment variables can be gotten by typing SET at a command prompt.

And here’s the really cool part! You can make them up as you go along, and assign them as you wish (as long as you don’t grab one that has a legitimate assigned value, such as, say, %windir%, the Windows directory name!). Pick a name, populate it with the SET command by any means known to you (including having one batch file run a process that includes setting one, and then another batch file using it), then use it by placing the name between flanking % signs. Environment variables remain until overwritten, or until a reboot. (If you set them in a DOS window, they will end when that session is closed.)

If you precede an environment variable setting with the SETLOCAL command (on a line of its own), then environment variable changes are local to the batch file. They do not exist for any other process and they do not survive the completion of the batch file’s execution. You can turn this setting off by issuing an ENDLOCAL command later in the batch file.

Silly example: To change the current logged drive to D:, do the following:

SET GONEXT=D:
%GONEXT%

More practical example: You want to copy a file to the desktop of each user the next time they log into Windows. Each user logs into a different user profile, and the Desktop folder is in a unique location for each user. (The folder name will, of course, vary on non-English versions of Windows.) For a file called MYFILE.TXT, you can do this as follows on Windows 2000 or XP computers by using an environment variable %userprofile% which gives the path to the root of a given user’s profile:

COPY MYFILE.TXT %userprofile%\Desktop

START Command

The START command can launch a Windows program either by specifying the program name (and its command-line parameters), or by specifying a data file name that is associated with a particular program (one that would automatically launch if you clicked on it in Windows).

For example, if you have NOTEPAD.EXE associated with all TXT files, then you could open the file SOME.TXT in any of the following four ways:

NOTEPAD SOME.TXT
SOME.TXT
START NOTEPAD.EXE SOME.TXT
START SOME.TXT

Why use one or the other? Well, sometimes you may have to use one particular form to get a result — depending, for example, on how the particular program is coded. Though the first form usually will work, you may want, for example, to write a more general batch file to open any particular program and associated file — without knowing what the requirements of all such files might be. You could, then, write a general batch file line such as START %1% %2%.

One particular use of the START command is to launch the default browser and go directly to a URL, for example: START http://google.com

You may use any of four command line parameters with the START command. These go after the word START, but before the program name:

/minimized or /m
/maximized or /max
/restored or /r
/wait or /w

The first three determine the screen status in which the program opens. The last one forces the batch file to halt processing until the called program has finished executing. (This can be useful, for example, if you are loading multiple items in your windows Startup folder, and the nature of the programs require that one be finished before the next starts loading. Put them all in a single batch file, using the /wait parameter, and only put a shortcut to the batch file in the Startup folder.) Command line parameters of the START command can be combined in a single line. Example:

START /max /wait NOTEPAD.EXE SOME.TXT

IF and IF NOT Commands

There are three variations of the IF and IF NOT commands.

* IF EXIST: Execute the commandline only if a particular file exists:

IF EXIST some.txt COPY c:/some.dll %windir%/SYSTEM/some.dll
* Compare two text strings, and execute the commandline only if they are identical.

IF %HostWinBootDrv%==C SET WinDir=C:\WINDOWS
* Error testing: Check the exit code of the most recently run program. If it is equal to or greater than the number specified, execute the command:

IF ERRORLEVEL 4 ERASE trashfile.tmp /P

GOTO Command

You can set a label in a batch file by beginning a line with a colon. You can then go directly to that label with the GOTO command. The GOTO command searches both forward and backward in the batch file; that is, it simply goes to the label location, regardless of where it is in the file.

For example, in my batch file for removing the Happy99 virus, UNHAPPY.BAT, the following code was used to make sure a file was not deleted unless the original form of it (backed up by the virus under the name WSOCK32.SKA) is present:

IF NOT EXIST WSOCK32.SKA GOTO SavedIt
DEL WSOCK32.DLL
RENAME WSOCK32.SKA WSOCK32.DLL
:SavedIt

FOR Command

The syntax for this command is: FOR variable in (set list) DO command

The variable must be in the form of one alphabetic character preceeded by %%; e.g., %%v.

NOTE: The %% is necessary because this is in a batch file which, otherwise, would give a special meaning to a single %. However, if you run the FOR command outside of a batch file, simply from the system prompt, just use a single % in the variable name. (Tip from Steve Wisdom)

The set list is enclosed within parentheses. These values will be assigned to the variable successively. You can use any text enclosed in quotes, batch file commandline parameters, environment variables, or DOS file wildcard expressions.

The command can be any valid command that otherwise could be entered into the batch file as a line of its own. example:

FOR %%D in (SYSTEM, COMMAND, SHELLNEW, “Start Menu”) DO DIR “%windir%\%%D” /W

More Information on These Commands

Each of these options (START, IF, GOTO, FOR) is an actual DOS command. At a system prompt, type the command name followed by /? to get further help on these items.

Note that there may be particular capabilities that show up in one version of Windows, but not in another. For example, though DOS per se may well be dead in Windows XP, the commandline functions people most often associate with DOS are not dead at all! (We just don’t call them “DOS commands” anymore; we call them “command prompt commands”. But they’re the same thing.) In some cases, these commands have been made more powerful in Windows XP. In particular, if Win XP Command Extensions are enabled, each of these four has very greatly enhanced capabilities (see Win XP Help & Support to learn about Command Extensions). Take advantage of the opportunity to explore each of them with the /? help flag.

SOME EXAMPLES (that don’t even require Command Extensions): START has new flags that let you set the priority (/LOW, /NORMAL, /HIGH, etc.) of the application you are launching. IF has an ELSE option than greatly expands its power, but which requires a somewhat complicated syntax sometimes (which the /? help text covers reasonably well).

Since these START, IF, GOTO, and FOR are actual OS commands, they can be used from a system prompt just like DIR, COPY, or any other DOS command. This means that they can be used outside of a batch file as well. There are small differences or issues that you can easily discover in use, and discussion of which would go beyond the purpose of the present page. For anyone comfortable working at a DOS system prompt, this should present no significant problem.

Tips for smooth browsing

1. Change text size while browsing

While browsing, you may come across web pages that use too small or too large a text size to be comfortably readable. To change the size of the text, click View and then Text Size. Click the text size that you’d like from the options available.

2. Open links in new Internet Explorer windows

When you right-click a link on a Web page, it will open in a new Internet Explorer window. Another way of doing this is to press the SHIFT key and then left-click the link.

3. Set a home page of your choice

You can choose which website you’d like to view—such as your e-mail account, a favorite portal, your organization’ s website, and so on—every time you start Internet Explorer. Go to Tools and click Internet Options. Under Home page on the General tab, type or copy-paste the URL of the website. Click Use Blank if you want to start with a blank page. Click Apply and then OK.

4. Type URLs quickly

When you’re visiting a website for the first time, you don’t need to type the whole www.thiswebsite. com in the Internet Explorer address bar. Instead, just type the name of the website (such as msn) and press CTRL and ENTER together. However, this works only with .com pages, not with others like .org, .net, or .in.

5. Navigate Web pages quicker

In a long browsing session, you may find yourself going back and forth between Web pages to revisit what you saw a while ago. To simplify this task, right-click the Back button to see all the pages that you’d seen before the current page, and click the one that you want to visit. Similarly, you can right-click the Forward button to see the Web pages you visited from the current Web page.

6. Clear the Web cache

Internet Explorer stores frequently visited Web pages in a cache, so that if they haven’t changed since the last time you visited them, they are opened from your hard disk for faster access. However, if the cache becomes too full, IE may become slow. To clear the cache, click Tools and then Internet Options. On the General tab, under Temporary Internet files, click Delete Files. Click the checkbox against ‘Delete all offline content’ if you want to delete content that you’ve stored offline. Click OK and wait for your cursor to change from the hourglass to the arrow icon again. Then, click OK.

7. Open and close new IE windows quickly

If you like to surf for long hours, here are some keyboard shortcuts to open and close new windows for Web browsing. To open a new window in Internet Explorer, click CTRL and N. To close each window, click the ALT key and the F4 key together; or click CTRL and W.

8. Create Desktop shortcuts to your Favorite websites

If you have websites in your Favorites folder that you like to visit very frequently, you can create shortcuts to them on your Desktop. Open Internet Explorer and shrink its size using the square icon on the top-right corner, so that you can see your Desktop. Click Favorites and go to the saved link for your website. Drag the icon for this website and drop it to your Desktop. Your shortcut is ready.

9. Rename or delete Favorites quickly

You can organize the links stored in your Favorites list without going to Organize Favorites. Open Internet Explorer and click Favorites. Right-click the link that you want to rename or delete; and choose the desired option from the menu.

10. Arrange your Favorites in alphabetical order

You can sort your list of links under Favorites alphabetically. Open Internet Explorer and click Favorites. Right-click and link and then click Sort by name on the menu.

11. Make your Favorites pages available offline

If you have some existing links in the Favorites list that you’d like to make available for offline viewing, click Favorites and go to the link. Right-click and then click Make available offline in the menu.

12. Turn off alert for permanently deleting messages

When you decide to delete messages in your Deleted Items folder in Outlook, you are asked whether you’re sure you want to delete these messages. If you want to turn off this notification, click Tools, then Options, and go to the Other tab. Click Advanced Options here, and click the checkbox against ‘Warn before permanently deleting items’.

13. Remove messages from Outlook as you delete them

If you’d like to clear your Deleted Items folder daily, click Tools, then Options and go to the Other tab. Click the checkbox against the option ‘Empty the Deleted Items folder upon exiting’. Every time you close Outlook, all the items in your Deleted Items folder will be cleared.

14. Determine when to mark messages as read

If you view messages in the Reading Pane in Outlook, you can decide when the messages that you’ve read should be marked as such. Click Tools, then Options and go to the Other tab. Click Reading Pane. Click the checkbox against ‘Mark items as read when viewed in the Reading Pane’, and enter the number of seconds to wait before marking the message. Or, you can click the checkbox against ‘Mark item as read when selection changes’ if you want to mark the message as read when you move to another message. Click OK and then OK again.

15. Add or remove a column in Outlook 2007

In the main Outlook window, you can see lots of columns for your message list, such as Date, Subject and so on. To add or remove any of these columns, click View, go to Current View and then click Customize Current View. Click Fields. In the Available fields list, click the required field, and click Add or Remove.

16. Move a column in Outlook 2007

To change the order of columns that appear in the main Outlook window, click View, go to Current View and then click Customize Current View. Click Fields and go to the Show these fields in this order list. Click the required field, and then click Move Up or Move Down to change the field’s position.