History files and the Station Environment Variable

For general issues related to PWB v2.

Moderators: Tyler, Scott, PWB v2 Moderator

Post Reply
Scott
Site Admin
Site Admin
Posts: 2528
Joined: Mon Dec 16, 2002 12:31 pm
Location: Rochester, MN
Contact:

History files and the Station Environment Variable

Post by Scott »

The station environment variable is used by PWB for the history file. The environment variables are a set by the computer each time someone logs on. The variables can be viewed or modified by opening the system properties (Windows NT/2K/XP) or the Autoexec.bat file (Windows 95/98/ME), or from a command prompt by typing SET and hitting the enter key. PWB is able to read these variables and use them in the history file.

Under normal circumstances Windows set an environment variable named COMPUTERNAME that stores the computer name. This is the variable that you would use to identify the computer in a shared INI history file scenario. There are other variables that can be used as well including USERNAME, or any environment variable you create. In the PWB INI file, you are telling PWB what variable to use when writing the history file.

To use multiple history files with a single shared INI file, you can use the Use Unique History Files setting to append the Station Environment Variable onto the history file name.

[Files]
...
HistoryFile=History.txt
...

[Security]
StationEnvironmentVariable=COMPUTERNAME
UseUniqueHistoryFiles=True
...

Using these settings on a computer named COMP1, your history file would be named something similar to the following.

...\Public Web Browser v2\HistoryCOMP1.txt

The history file would take on the format

COMP1 07/07/03 10:12:15 <-> www.google.com
COMP1 07/07/03 10:13:28 <-> www.yahoo.com
COMP1 07/07/03 10:14:19 <-> www.excite.com

--Scott

Post Reply