About the initialization file

PK.INI is a text file containing variables that specify your PocketBuilder preferences. These preferences include information such as the last workspace you used and your startup preferences. When you perform certain actions in PocketBuilder, your preferences are written to PK.INI automatically.

Format of INI files

PK.INI uses the Windows INI file format. This file has three types of elements:

A variable can be listed with no value specified, in which case the default is used.

Some sections are always present by default, but others are created only when you specify different preferences. If you specify preferences for another painter or tool, PocketBuilder creates a new section for it at the end of the file.

Specifying preferences

Normally you do not need to edit PK.INI. You can specify all your preferences by taking an action, such as resizing a window or opening a new application, or by selecting Design>Options from one of the painters. If a variable does not appear by default in the options sheet for the painter, you can use a text editor to modify the variable in the appropriate section of PK.INI.

NoteEditing the initialization file Do not use a text editor to edit PK.INI or any preferences file accessed by Profile functions while PocketBuilder or your application is running. PocketBuilder caches the contents of initialization files in memory and overwrites your edited PK.INI when it exits, ignoring changes.

Where the initialization file is kept

PK.INI is installed in the PocketBuilder user's private application data directory. For Windows XP and Windows 2003, this is typically the C:\Documents and Settings\userName\Local Settings\Application Data directory, where userName is the name of the current PocketBuilder user. For Windows Vista, this is typically the C:\Users\userName\AppData\Local directory.

A copy of the PK.INI is installed in the same directory as the PocketBuilder executable file. PocketBuilder does not normally use this copy, however, you can change the location of the operative PK.INI file in the System Options dialog box. You might want to do this if you use more than one version of PocketBuilder or if you are running PocketBuilder over a network.

StepsTo record your initialization path:

  1. Select Tools>System Options from the menu bar.

  2. On the General tab page, enter the path of your initialization file in the Initialization Path text box.

    PocketBuilder records the path in the Windows registry.

How PocketBuilder finds the initialization file

PocketBuilder looks in the Windows Registry for a path to the file, and then looks for the file in the directory where PocketBuilder is installed. If PocketBuilder cannot find PK.INI using the path in the Registry, it clears the path value.

If PocketBuilder does not find PK.INI when it starts up, it recreates it. However, if you want to retain any preferences you have set, such as database profiles, keep a backup copy of PK.INI. The recreated file has the default preferences.