I need help with custom controls and "reusable code".
Example:
1) I have made a custom control "lb" that only contains a listbox.
2) I then make a diaglog box "dlg" and insert my new custom control "lb"
3) Now I want to take action in dlg.pro on any selectionChange made in the custom control "lb". In other words "dlg" need to be notified of a selectioncHANGE In "lb"
In lb.pro
Code: Select all
facts
                senderdlg : containerWindow :=erroneous.
                
clauses
        new(Parent) :-
                new(),
                setContainer(Parent),
                senderContainer:=Parent.
       
        new() :-
                userControlSupport::new(),
                generatedInitialize().
                        
        onListboxSelectionChanged(_Source) :-
                senderdlg:selectionChanged()
                !.
                Code: Select all
interface dlg supports dialog
    open core
 
        predicates
                selectionChanged : ().
 
end interface dlgCode: Select all
clauses
        selectionChanged() :-
        stdio:write("Selection changed"),
        !.e229 Undeclared identifier 'selectionChanged/0' lb.pro ..\myCollection\lb\
Naturally , I would like to use my custom control in many different dogs (different classes)
Can you advise ?
Thanks in advance
Dave Plummer
