[Lazarus] Invalid component names

Benito van der Zander benito at benibela.de
Mon Apr 27 13:05:47 CEST 2009

>> So the remaining question is: How to assign unique names to
>> dynamically created components? Does there exist an immediately
>> usable method or function?
For wincontrols you could use this:

Handle is system-wide unique (at least on Win32)

However, some properties can change the handle imho,
than you should either set the new name or hope the handle will not be 
used again.

Or you could use this: (name depending on the current time and a random 
number if several controls are created in one milli-second)


More information about the Lazarus mailing list