Lets say I have an intraweb application (written in Delphi 2010) with an iwEdit (called iweLookup) and an iwButton (iwbSearch). When enter is pressed in the iwEdit, I want the iwButton clicked.
The following code almost works, but I think I need something to re-render the page.
procedure TiwfLookupListing.iweLookupAsyncKeyDown(Sender: TObject;
EventParams: TStringList);
begin
if EventParams.Values['which'] = '13' then
begin
iwbSearchClick(Sender);
end;
end;
However this requires a round trip to the server (which would be acceptable but not desirable). Ideally I'd like a way of doing it in Javascript - presumably in the ScriptEvents for the iwedit (but my Javascript skills are currently, um, limited)
Can anyone point me in the right direction?