diff --git a/examples/local_file_picker/local_file_picker.py b/examples/local_file_picker/local_file_picker.py index 4243bbaa8..d31fc3bab 100644 --- a/examples/local_file_picker/local_file_picker.py +++ b/examples/local_file_picker/local_file_picker.py @@ -78,5 +78,5 @@ def handle_double_click(self, e: events.GenericEventArguments) -> None: self.submit([str(self.path)]) async def _handle_ok(self): - rows = await ui.run_javascript(f'getElement({self.grid.id}).gridOptions.api.getSelectedRows()') + rows = await self.grid.get_selected_rows() self.submit([r['path'] for r in rows])