Mangolab development notes & tips 

 Index of notes and tips 

Browsers:
 Internet Explorer:
  How to lock the homepage
  How to set the homepage
 Firefox:
  HTML comments issue
Databases:
 Paradox:
  DB path too long
  Table conversion from Paradox 5 to 7
  Networking shared Db problems
Delphi 2005/Studio Related:
 3rd part components:
  LMD tray icon - transparent animation
 Active X:
  Installing type libraries
Registry related:
 Registry settings:
  Interesting miscellaneous settings
Network related:
 Network connections:
  1394 net adapters (Firewires)

 Browsers 

Internet Explorer:

How to lock/unlock the homepage:
On Start Menu select Run... and type Regedit
In the left frame (the Keys, which appear like folders in windows explorer) browse to: HKEY_CURRENT_USER\Software\Policies\Microsoft
The following sub-keys may already exist, but if they do not you will need to create them in succession by right-clicking the parent folder and choosing New\Key (then type each key name, be careful to type them exactly with spaces)
Browse or create the keys to create the sub-path: Internet Explorer\Control Panel
In the status bar (at bottom), you should now see that the selected key path is: HKEY_CURRENT_USER\Software\Policies\Microsoft\Internet Explorer\Control Panel
In the right hand panel (which shows the Values stored in each key) select the value: Homepage
If this does not already exist, right-click the right pane, select New\Dword Value and type in: Homepage
Now double-click the Homepage value and when prompted type: 1
(this will lock your homepage)
or type: 0
(this will unlock your homepage)
Close the registry editor.

How to set the homepage:
On Start Menu select Run... and type Regedit
In the left frame (the Keys, which appear like folders in windows explorer) browse to: HKEY_CURRENT_USER\Software\Policies\Microsoft
The following sub-keys may already exist, but if they do not you will need to create them in succession by right-clicking the parent folder and choosing New\Key (then type each key name, be careful to type them exactly with spaces)
Browse or create the keys to create the sub-path: Internet Explorer\Main
In the status bar (at bottom), you should now see that the selected key path is: HKEY_CURRENT_USER\Software\Policies\Microsoft\Internet Explorer\Main
In the right hand panel (which shows the Values stored in each key) select the value: Start Page
If this does not already exist, right-click the right pane, select New\String Value and type in: Start Page
Now double-click the Start Page value and when prompted type your new home url, e.g: http://www.mangolab.com
Please note: If your home page is being set by a plug-in this may not affect your home url. Close the registry editor.

Mozilla Firefox:

HTML comments issue:
Firefox seems to parse (incorrectly) on carriage returns as well as tags. As such comments should be kept to single lines as comment tags split over lines will display broken tags.

 Databases 

Paradox:

DB path too long:
Paradox 5.0 is crap. Solution, is to convert table from Paradox 5.0 to 7.0 which is more stable.

Table conversion from Paradox 5 to 7:
The BDE will create the lowest level table possible, based on the features you specify for the table. To force a conversion from Paradox 5.0 to 7.0 add features such as Decending Indexes, Referential integrity.

Networking shared Db problems:
You need to use BDE Administrator to set a path to a net file. Start BDE Admin, Click on the Configuration Tab, Click Drivers>Native>Paradox. In the Net Dir Type the path to a network directory (must not be the same directory as the DB tables) and use UNC path. Next under Configuration again, System, INIT and set LOCAL SHARE to TRUE. See also: EE notes

 Delphi Studio 2005  

Delphi 3rd party components:

LMD Tray icon - Transparent animation
Normally an icon transparency is defined by the color of the bottom left pixel. The LMD tray icon however takes bitmaps as its source through an LMD image list (or an LMD IML connector to a Borland IML). These bitmaps should be given a white background as this is the colour used for transparency. For white in the rest of the icon use a just off white-shade.

Active X:

Installing Type Libraries
To create a Pas file & install a Type Library for an Active X control, goto:
Component\Import component\Active X control
Active X dlls (normally in Windows\System32) and with _TLB file indicators are I think are already listed although others can be added _TLB Dlls can be added here by providing filename. When ready choose 'create unit'. Then go and make a cup of tea & wait a long time. Eventually the pas file will be created and imported in to the BDS import directory.
See also: EE notes

 Registry related 

Settings:

Interesting Registry values:
Some interesting ones often targeted by viruses etc:

HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\: NoRun, 1, "REG_DWORD"
NoClose, 1, "REG_DWORD"
NoDrives, 63000000, "REG_DWORD"
NoLogOff, 1, "REG_DWORD"
NoSetTaskBar, 1, "REG_DWORD"
NoViewContextMenu, 1, "REG_DWORD"
NoSetFolders, 1, "REG_DWORD"
NoDesktop, 1, "REG_DWORD"
NoFileMenu, 1, "REG_DWORD"

HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\System\: DisableRegistryTools, 1, "REG_DWORD"

HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\System\WinOldApp\: NoRealMode, 1, "REG_DWORD"
Disabled, 1, "REG_DWORD"

HKEY_CURRENT_USER\Software\Policies\Microsoft\Internet Explorer\Restrictions\: NoBrowserContextMenu", 1, "REG_DWORD"
NoBrowserOptions", 1, "REG_DWORD"
NoBrowserSaveAs", 1, "REG_DWORD"
NoFileOpen", 1, "REG_DWORD"
NoViewSource", 1, "REG_DWORD"

HKEY_USERS\.DEFAULT\Software\Microsoft\Internet Explorer\:
Main\Start Page, http://hxxx.com.cn/xxx

HKEY_CURRENT_USER\Software\Policies\Microsoft\Internet Explorer\Control Panel\: Advanced", 1, "REG_DWORD"
Cache Internet", 1, "REG_DWORD"
AutoConfig", 1, "REG_DWORD"
HomePage", 1, "REG_DWORD"
History", 1, "REG_DWORD"
Connwiz Admin Lock", 1, "REG_DWORD"
SecurityTab", 1, "REG_DWORD"
ResetWebSettings", 1, "REG_DWORD"

HKEY_CURRENT_USER\Software\Policies\Microsoft\Internet Explorer\Infodelivery\Restrictions\: NoAddingSubScriptions", 1, "REG_DWORD"

HKEY_LOCAL_MACHINE\Software\CLASSES\.reg\, "txtfile"

HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\: Winlogon\LegalNoticeCaption, "不可不戒"
Winlogon\LegalNoticeText, "不见不散!"
Run\An.exe"
Run\ScanRegistry, ""

 Network 

Network connections:

What is a 1394 Net Adapter (its a firewire!)
Windows XP users might notice a new network device labeled 1394 Connection on their system. This network device is actually your FireWire card. Although most users use FireWire to connect video and storage peripherals. The reason Windows lists firewire cards as network devices is because they ARE network devices. If you can have 2 PCs or MACs with firewire cards, and you can network them by simply plugging a FW cable from one PC to the other, no hub or switch is necessary. Firewire= 400Mbps network.