To keep the department/cities sample; i'll try to explain you how i did it in Designer:
I created a "variable" bloc (at the bottom of the Hierarchy tab) called Cities
An other one called Departments
A last called CitiesFunctions
In the Cities bloc, i declared an array with all cities.
In the Department bloc, I declared an array by department. In each array, i have 2 items : the index of the first city of the department in the cities tab and the index of the last city of the department in the cities tab.
On my form, I created a dropDownList called Department (populated with departments) and an other called cities initialized empty.
On Department change event:
I rase the cities field.
I call my function getCitiesByDpt in my CitiesFunctions bloc with the department in parameter.
In these function I call the array corresponding to the department in the Cities bloc and I populate my listBox cities by the results (tab of cities from parameter 1 to parameter 2 of my Department array).
Carrefull : if a list has too much items, you should create a "manual list" composed of 1 textField, 1 button, 1 listBox (it's better for performance)
After than, always by script, you can restrict you second list by the sequence of characters eventualy keyed in the field Cities.
I hope i'm a little beat clear ! it's hard to explain in a forum (and sorry for my french english...:))
Pierre.