# Pass values from one component to another

**URL:** <https://community.bloomreach.com/t/pass-values-from-one-component-to-another/1273>\
**Category:** Experience Manager (PaaS/OnPrem)\
**Created:** [July 19, 2019, 7:31am UTC](https://community.bloomreach.com/t/pass-values-from-one-component-to-another/1273 "2019-07-19T07:31:48Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![renjini.pillai](https://avatars.discourse-cdn.com/v4/letter/r/7bcc69/32.png) [@renjini.pillai](https://community.bloomreach.com/u/renjini.pillai)\
**Post date:** [July 19, 2019, 7:31am UTC](https://community.bloomreach.com/t/pass-values-from-one-component-to-another/1273/1 "2019-07-19T07:31:48Z")

</div>

I would like to understand how i can pass a value on form submit from one page to another.

I have a form submit from one component

Component class doAction() method

```
 @Override
    public void doAction(HstRequest request, HstResponse response) throws HstComponentException {

        FormMap map = new FormMap(request, new String[]{"test"});
        
        HstRequestContext context = request.getRequestContext();

        final HstLinkCreator hstLinkCreator = context.getHstLinkCreator();
        final HstLink hstLink = hstLinkCreator.create("/accelerator", context.getResolvedMount().getMount());

        **FormUtils.persistFormMap(request, response, map, null);**
        
        try {
            response.sendRedirect(hstLink.toUrlForm(context, false));
        } catch (IOException e) {
            log.warn("Error redirecting to 404 page: ");
        }
    }

```

When i persist the formMap i am able to retrieve this value on the same components doBeforeRender() method. But since i have to redirect the request to another sitemap (page) how can i retrieve the value in another page ?
