Remember values in input/label fields after page is refreshed/reopened

Hi,

I have an app with 2 pages, and I am determining the values of some input and label fields with a bot. All good until I leave the page. The question is: is there any way to “save” these values inside the App permanently, like some variables, so that when I refresh/reopen the page, they will not disappear ?

Or does anybody have any workaround to achieve this effect ?

Thank you,
Gabi.

Normally, you wouldn’t leave the page unless you are starting a new transaction to process, which then you would just input the values again.

What I would suggest is when you go back to that page, you should be invoking or calling the sequence that performs the input fields. And, in this sequence, you should get the value in each field that you wish to input prior to inputting the value. You can get the value using Get Attribute or Get Text activity.

Then, using an IF check that the value does not equal the value you want to input. This way, you can input the value only if it doesn’t have that value.

In most cases, you should know what you want to input each time you enter the page based on some data set from Excel or a similar source. So, there’s really no need to store the existing input values globally.

However, if you require this, then you would need to create ‘out’ argument(s) in the sequence that interacts with the page, so you can store the existing values globally and use again for the next transaction or other sections of your automation.

I don’t know if this answers your question, but it was just some thoughts.

Thanks.

Thx for the ideas, Clayton. I was thinking in the same direction. When you mention storing the values globally, do you mean in something like Assets ?

There is nothing additional for Apps, right ?

Thx,
Gabi.

When I said ‘globally’, I meant global to the process that is currently running, and not to the entire Robot landscape. Global variables are just seen by all workflows within the process running, so they are declared in the outermost .xaml of your project. And, whenever you invoke another .xaml, you would either send in those variables or return those variables back so other .xamls can use the values stored globally.

If you opt to use Assets for global values, then this would be more for if there is a value you want to share between multiple Robot users or different projects.

Generally, when you are interacting with a webpage to input values into fields, the values come from a source such as an Excel file. If they are constant values that are the same everytime, then you would normally want to store these into a config file that is read at the start of the process, so it can store those values globally. You can use Assets for constant values rather than a config file, however, I find that this clutters the Asset Manager, and I would only suggest this option if multiple projects share these values.

I’m not sure I understand this question and if you mean UiPath Apps which was recently introduced, I am not that familiar with it yet.

You can also explore the Marketplace in case there is something that helps with your ideas.

Yes, my question refers to the recently Introduced UiPath Apps :slight_smile:

But nevertheless your answer was helpful ! Thx !

I got the solution from somebody from the UiPath Community, and I thought I would share it here - the best solution is using the UiPath Data Service. Currently it is done via a bot, but I understand that soon it will be done directly from UiPath Apps, without the need to call a bot for it.

I have demonstrated the solution - you can jump to minute 10:55 :slight_smile: