Open greysteil opened 3 weeks ago
Thank you for letting us know about this issue. We will take a look shortly. Thanks.
Hi @greysteil Thanks for reporting this issue. I can repro it. We'll take a look and report back if we have a suggestion for you.
Hi @greysteil,
Is your use case that the end users need to keep both advanced search dialog and your search pane open at the same time?
The user has the advanced search dialog open for some reason that's unrelated to our add-in (it's just the way they're doing their work). I'd like to avoid having to ask them to close it, because I don't want our add-in to intrude on the way they're doing their other work.
Basically I want my add-in to be as un-intrusive as possible - it shouldn't make users take actions they don't want to / don't expect to have to take. The inability to use search(...)
if the user has the advanced search dialog open is forcing me to ask the user to take an action that they wouldn't expect to have to take - to them, the fact my add-in uses search(...)
to do its work, and that that's incompatible with the advanced search window being open, are implementation details they don't want to think about.
Provide required information needed to triage your issue
Using the
search(...)
function when a user has the advanced search dialog open throws aSearchDialogIsOpen
error.Your Environment
Expected behavior
Using
search(...)
should return results regardless of whether the user has the advanced search dialog open.Current behavior
Using the
search(...)
function when a user has the advanced search dialog open throws aSearchDialogIsOpen
error.Steps to reproduce
SearchDialogIsOpen
errorContext
The
search(...)
function is critical to our app. We use it to find and then track locations in the document, which we then annotate, suggest changes to, scroll to, etc.. Without it we have no way to get those locations.As a result of this issue, we have to show an error message in our app when a user has the advanced search dialog open and we try to do almost anything. The user then has to close the search dialog in order to perform actions from our app.
I'm guessing the presence of a specific error for this case means it's a known issue on the OfficeJS side, but I'm opening this issue because
search(...)
is foundational to so many apps (I'm sure my use cases aren't unusual). Would it be possible to support API searches even when the advanced search dialog is open?