Alexander Bulei wrote:Hi yocko,
Please send us the simple testcase project. TIA
I am populating DropDown from a DBISAM Table. I suppose you don't have Dbisam there...
All non DB related code is already posted. After I create a frame I assing value to DropDownCountries.val property. That value (for example country name 'Portugal' is visible as preselected in DropDownCountries when frame gets visible. So far everything is OK. Preselecting some value is working. Then I click on button (see video in my previous post) to display DropDownCountries val value with WebApplication.ShowMessage and it returns ''
So:
- populating DropDown from DB table
is working OK- preselecting some value in frame create with assigning value to DropDown's val property
is working OK and preselected value is visible in DropDown when frame gets visible. But after this preselection process DropDown's property val is empty!!!
My question: are you clearing val property after lookup in DropDown is executed? - Code: Select all
ListDataSet.Lookup(ListSelectFieldName,v,ListLookupResultFieldName)
Otherwise it can't be '' (empty string) if I assigned value 'Portugal' to it when frame was created, and first thing I do when I come to frame is clicking on button to execute:
- Code: Select all
WebApplication.ShowMessage('val is: '+DropDownCountries.val)...
So where is value from DropDownCoutries.val property cleared to empty string? Somewhere in between event
frame create (where val:='Portugal'), to event
frame is visible (where I click on button to test val value and it is already an empty string).
One process in between these two events is for sure DropDown's lookup execution, so there something must be wrong... After lookup is finished and some value is preselected ('Portugal' is visible), val poperty should also have value 'Portugal' and not empty string ''...
Regards
P.S:
Additional test from today:
if I have this in on frame create
#1
- Code: Select all
DropDownCoutries.val:='Portugal';
val property is empty string when frame gets visible.
#2
if I have this in on frame create
- Code: Select all
DropDownCoutries.val:='Portugal';
DropDownCountries.JQDropDownOptions.Open;
DropDownCountries.JQDropDownOptions.Close;
val property is no more empty string when frame gets visible.
