diff --git a/PowerEditor/src/ScintillaComponent/FindReplaceDlg.cpp b/PowerEditor/src/ScintillaComponent/FindReplaceDlg.cpp index 92370ea31..60c444c8b 100644 --- a/PowerEditor/src/ScintillaComponent/FindReplaceDlg.cpp +++ b/PowerEditor/src/ScintillaComponent/FindReplaceDlg.cpp @@ -3984,11 +3984,9 @@ void Finder::removeAll() void Finder::openAll() { - size_t sz = _pMainFoundInfos->size(); - - for (size_t i = 0; i < sz; ++i) + for (auto&& path : getResultFilePaths()) { - ::SendMessage(_hParent, WM_DOOPEN, 0, reinterpret_cast(_pMainFoundInfos->at(i)._fullPath.c_str())); + ::SendMessage(_hParent, WM_DOOPEN, 0, reinterpret_cast(path.c_str())); } }