Board index » delphi » ISelectionServicesListener
Tim
![]() Delphi Developer |
ISelectionServicesListener2005-03-19 07:55:42 AM delphi196 I am playing with th ISelectionServicesListener interface. I got it partially working, but I am running into an error and wondering if anyone has found a solution. I have a TSelectionServicesListener = class (TInterfacedObject, ISelectionServicesListener) in my method where I add my custom behaviors, I also am adding the listener to the browser: SelectionListener := TSelectionServicesListener.Create; serviceProvider := WebBrowser1.Document as IServiceProvider; serviceProvider.QueryService(SID_SHTMLEditServices, IID_IHTMLEditServices, editServices); markupContainer := WebBrowser1.Document as IMarkupContainer; editServices.GetSelectionServices(markupContainer, selectionServices); selectionServices.SetSelectionType(SELECTION_TYPE_Control,SelectionListener); This all works ok. If I select an element, the OnChangeType method of the ISelectionServicesListener gets called - although only the first time. In addition, I am getting a "Member not found" error, although it's not an exception (just a message box). Any help would be greatly appreciated. Thanks, Tim |