2023 R2: Workaround for the ShowContent() symbols not disappearing on context change anymore

Hi all,

We're currently testing the new System Platform 2023 R2, and found out symbols that have been displayed with a ShowContent() do not disappear anymore when the context changes. Support confirmed to us that this is on purpose and not a bug, even if I'm struggling to understand the point...

The way we've designed our layout, symbols like motor controls are displayed on operator actions with a ShowContent and it doesnt make sense to keep them open when the context changes.
Our idea for a workaround was to have a layout script executed on every context change, that basically goes that way for every pane we want to clear:

dim contentInfo as aaContent.ContentInfo;
contentInfo.PaneName = "NameOfThePane";
contentInfo.ContentType = "App_Device_Faceplate";
HideContent(contentInfo);

The contentType is used to avoid wiping the auto-fill content when the script runs after the autofill has already happened, as only the ShowContent() symboles are using the App_Device_Faceplate content type.

The current issue with this basic script is that it runs without checking if there is matching content in the pane, generating logs when there isnt.

Would anyone have ideas on how to improve that script, or a whole different solution we didnt think of ?
I doubt we'll be the only ones struggling with that new feature, as we've seen others use the same mechanism.

Thanks

Parents
  • Occassionally we make some changes to improve performance characteristics of OMI - in this case it broke an exisiting experience which we deem to be a regression (something worked and does not anymore).  The issue should be fixed in the upcoming Patch 01 (targeted for early July).

    It did make me wonder if this should not be something optional - in some cases, I might want the manually shown content to stick around after changing context... Or will that never be the case? I do agree that by default it should disappear, I was just wondering if anyone has a use case for making it stay put...

Reply
  • Occassionally we make some changes to improve performance characteristics of OMI - in this case it broke an exisiting experience which we deem to be a regression (something worked and does not anymore).  The issue should be fixed in the upcoming Patch 01 (targeted for early July).

    It did make me wonder if this should not be something optional - in some cases, I might want the manually shown content to stick around after changing context... Or will that never be the case? I do agree that by default it should disappear, I was just wondering if anyone has a use case for making it stay put...

Children
No Data