# Why can't we close PegaSocial-Document case directly from screen?

**URL:** <https://forums.pega.com/t/why-cant-we-close-pegasocial-document-case-directly-from-screen/4989>\
**Category:** User Experience\
**Tags:** 8-8, user-experience, case-management\
**Created:** [September 5, 2023, 3:57am UTC](https://forums.pega.com/t/why-cant-we-close-pegasocial-document-case-directly-from-screen/4989 "2023-09-05T03:57:50Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![CloeW938](https://avatars.discourse-cdn.com/v4/letter/c/8e8cbc/32.png) [@CloeW938](https://forums.pega.com/u/CloeW938)\
**Post date:** [September 5, 2023, 3:57am UTC](https://forums.pega.com/t/why-cant-we-close-pegasocial-document-case-directly-from-screen/4989/1 "2023-09-05T03:57:50Z")

</div>

Hello,

When we attach a file to a case, system automatically creates an instance of PegaSocial-Document class. This case can be opened in a separate OOTB screen as below. This thread comes on top of your case that you are working on right before. End user simply wants to close this Document thread but current PRPC does not seem to have that feature. End user doesn’t want to use browser’s back button because browser button is not supposed to be used in a web application in general. PRPC is no exception. Hopefully it should have a close (X) button on top right.

My question is why product team did not add such basic function. Any specific limitation? I believe eliminating an opened thread is a very fundamental feature that product must have.

 ![PegaSocial-Doc.png](https://pega1.discourse-cdn.com/pega/original/2X/3/318321768db0d6cab3417cfcc3eaa0853b43a2f1.png)

Regards,

---

<div class="post-metadata">

**Author:** ![MarijeSchillern](https://yyz2.discourse-cdn.com/pega/user_avatar/forums.pega.com/marijeschillern/32/23321_2.png) [@MarijeSchillern](https://forums.pega.com/u/MarijeSchillern)\
**Post date:** [September 5, 2023, 9:22am UTC](https://forums.pega.com/t/why-cant-we-close-pegasocial-document-case-directly-from-screen/4989/2 "2023-09-05T09:22:02Z")

</div>

@CloeW938 The absence of a close button for the document thread in Pega is due to the design of the Cosmos UI, which uses a single page dynamic container. In this design, it is intended for users to navigate using the left-hand pane or browser buttons rather than closing the existing thread. However, you can customize the UI to add a close button if needed, but it is not a default feature in the Cosmos UI.

This answer came from a Pega gen-AI assistant using the below references. As a Support Center moderator, I reviewed the answer and references for accuracy:

[PEGA Portal issue with close button](https://support.pega.com/question/pega-portal-issue-close-button)

[Close button on case redirects to Home page instead of previous landing page fro](https://support.pega.com/question/close-button-case-redirects-home-page-instead-previous-landing-page-where-case-opened)

\*\*\* Pega 8.8 documentation link pointing to ‘Browser Back Button Functionality’ added after SME comment \*\*\*\*

[Creating and managing cases](https://docs.pega.com/bundle/platform-88/page/platform/case-management/creating-managing-cases.html)

 ![brwoser back.png](https://pega1.discourse-cdn.com/pega/original/2X/e/ed2c450d1af7c4b31add36818522910c1a37ea3c.png)

---

<div class="post-metadata">

**Author:** ![CloeW938](https://avatars.discourse-cdn.com/v4/letter/c/8e8cbc/32.png) [@CloeW938](https://forums.pega.com/u/CloeW938)\
**Post date:** [September 6, 2023, 1:21pm UTC](https://forums.pega.com/t/why-cant-we-close-pegasocial-document-case-directly-from-screen/4989/3 "2023-09-06T13:21:57Z")

</div>

@MarijeSchillern

Thanks for the response. However, it is very painful for customer to click menu in left pane to come back to the same page. So I guess everyone would use browser back button. I thought browser back button is not supported. Actually most of web application in general won’t work well if browser back is used. Isn’t that true?

Can you please indicate official support statement regarding browser back button?

Regards,

---

<div class="post-metadata">

**Author:** ![MarijeSchillern](https://yyz2.discourse-cdn.com/pega/user_avatar/forums.pega.com/marijeschillern/32/23321_2.png) [@MarijeSchillern](https://forums.pega.com/u/MarijeSchillern)\
**Post date:** [September 6, 2023, 5:02pm UTC](https://forums.pega.com/t/why-cant-we-close-pegasocial-document-case-directly-from-screen/4989/4 "2023-09-06T17:02:44Z")

</div>

@RichardMarsot can you answer this question?

---

<div class="post-metadata">

**Author:** ![CloeW938](https://avatars.discourse-cdn.com/v4/letter/c/8e8cbc/32.png) [@CloeW938](https://forums.pega.com/u/CloeW938)\
**Post date:** [September 11, 2023, 10:11am UTC](https://forums.pega.com/t/why-cant-we-close-pegasocial-document-case-directly-from-screen/4989/5 "2023-09-11T10:11:40Z")

</div>

@Rekha.Rani

Thanks for the info about Infinity '23. However, our customer is using Pega 8.8 and my question in the last thread was specifically about browser back button. **Is browser back button supported by Pega?** If yes, can you please indicate official support statement regarding browser back button?

Regards,

---

<div class="post-metadata">

**Author:** ![RichardMarsot](https://yyz2.discourse-cdn.com/pega/user_avatar/forums.pega.com/richardmarsot/32/23530_2.png) [@RichardMarsot](https://forums.pega.com/u/RichardMarsot)\
**Post date:** [September 11, 2023, 7:00pm UTC](https://forums.pega.com/t/why-cant-we-close-pegasocial-document-case-directly-from-screen/4989/6 "2023-09-11T19:00:01Z")

</div>

@CloeW938

several comments on this thread:

1/ Theme-Cosmos UserPortal and the UI-Kit pyCaseWorker portals are both using the single page dynamic container and are updating the page history when navigating to a new page - You can use the back button to get back to the previous pages - this is a very typical pattern in most web applications - You will not find a web site with a ‘close’ button.

2/ If you really want to add a close button on the document page, you can customize the harness and add it

3/ The default attachment widget will create a document and reference it - for some application, you don’t want to link to a doc object and want to attach directly to the case - in this case you can following this article to bring back the old widget [How to bring back the old attachment utility in Theme Cosmos | Support Center](https://support.pega.com/discussion/how-bring-back-old-attachment-utility-theme-cosmos)

browser’s back button support is mentioned in several articles:

- [Pegasystems Documentation](https://docs-previous.pega.com/whats-new-pega-platform/enhance-case-processing-experience-theme-cosmos-applications-86) =\> For example, if you apply filters and sorting to a list, and then open a new document, the application retains the table settings when you navigate back to the page by clicking the **browser back** button.
- [Pegasystems Documentation](https://docs-previous.pega.com/case-management/85/creating-and-managing-cases) =\> You can conveniently switch between cases with your **browser’s back button** and follow navigable breadcrumbs to trace relationship between related work
- [Ask the Expert - Cosmos UI with Sam | Support Center](https://support.pega.com/discussion/ask-expert-cosmos-ui-sam)

---

<div class="post-metadata">

**Author:** ![CloeW938](https://avatars.discourse-cdn.com/v4/letter/c/8e8cbc/32.png) [@CloeW938](https://forums.pega.com/u/CloeW938)\
**Post date:** [October 25, 2023, 8:22am UTC](https://forums.pega.com/t/why-cant-we-close-pegasocial-document-case-directly-from-screen/4989/7 "2023-10-25T08:22:10Z")

</div>

@CloeW938

I have created a “Close” button on Document screen as below. Close function itself works, but I was expecting that Work Object (in this example P-3001) is displayed. However, it seems user is taken back to Home screen. This is not what I want.

 ![Close button takes you to Home.png](https://pega1.discourse-cdn.com/pega/original/2X/7/7f4e6a5ca3213282fd09691ed5f709633bdf545f.png)

Here is how I created Close button.

 ![Close configuration.png](https://pega1.discourse-cdn.com/pega/original/2X/0/02ad487e568e1b67e678d5f37cd9e58a3881f0af.png)

Did I do anything wrong? Can I make case screen appear right after I close the PegaSocial-Document screen?

Regards,

---

<div class="post-metadata">

**Author:** ![KenshoTsuchihashi](https://yyz2.discourse-cdn.com/pega/user_avatar/forums.pega.com/kenshotsuchihashi/32/16482_2.png) [@KenshoTsuchihashi](https://forums.pega.com/u/KenshoTsuchihashi)\
**Post date:** [October 25, 2023, 8:46am UTC](https://forums.pega.com/t/why-cant-we-close-pegasocial-document-case-directly-from-screen/4989/8 "2023-10-25T08:46:25Z")

</div>

@CloeW938

When you open up PegaSocial-Document work item, the previous case type (P-3001) Thread is already gone from the clipboard. So you would need to newly open P-3001 manually. Add another button (ex. “Go to associated case”) to open the case. The case ID is stored in PegaSocial-Document’s _pyTopCaseID_ property.

 ![Open work item.png](https://pega1.discourse-cdn.com/pega/original/2X/d/da6767520e821b62fe14906316a80e9867830c88.png)

Also, PegaSocial-Document work item can be created by itself without having any associated work item and you need to consider this pattern as well. It might be a good idea to control visibility so this button won’t be displayed if there is no associated case.

 ![Go to associated case visibility.png](https://pega1.discourse-cdn.com/pega/original/1X/97c60f29c07f2e76608ea5c88361ff8bf298c681.png)

Thanks,

---

<div class="post-metadata">

**Author:** ![Rekha\_Rani](https://yyz2.discourse-cdn.com/pega/user_avatar/forums.pega.com/rekha_rani/32/23380_2.png) [@Rekha\_Rani](https://forums.pega.com/u/Rekha_Rani)\
**Post date:** [September 11, 2023, 5:03am UTC](https://forums.pega.com/t/why-cant-we-close-pegasocial-document-case-directly-from-screen/4989/9 "2023-09-11T05:03:00Z")

</div>

@CloeW938 What release of Pega are you on?

As mentioned by Marie in Cosmos single page design we replace the current Case to open the Document (As you know Document is a Case itself).

That said we have given a functionality in Infinity '23 where the Documents will be opened in a new tab by default and if user wishes to use the old behaviour they can override a when rule. Looks like this is something that might be helpful for you.

Regards,

Rekha
