Using variables in Object Repo UI Descriptors


We’ve found the object repo a really useful feature and it’s helped us expand our reuse first approach however we’re struggling to find a way to dynamically set the URL of the Browser or FilePath of an application when using the Use Application/Browser activity with an application from the Object Repo.

What we would like to be able to do is set the value of the URL or filepath by using a variable or argument but it appears we can only hardcode a string in these fields as any value we input has double quotes added at runtime.



The only way we’ve found so far that comes close to working is to pull in the application from the Object repo and then unlink it so that we can add a variable. This gives us a degree of reuse but means that if we make any updates to the UI Descriptor it won’t get picked up by any activities where we have unlinked from the Object Repo.

Is there any way we can set URLs or Filepaths in the applications in the Object Repo dynamically and for the descriptor in the Use Application/Browser to remain linked to the Object Repo

Hi @grlawlf,
You are correct that it is not currently possible to write a variable in the url field once the object is in the object repository
But, it is possible to have a variabile there if the url field is a variable before you link the “use app browser” to the object repository
So, you need to have an “use app browser” with url as in_URL and then link it to OR

Hi @Pablito,

Thanks for coming back on this and for the suggestion. This is something we already tried but it doesn’t work for us as UiPath adds quotes to the variable name and at runtime it takes the variable as the url. Essentially it tries to launch “in_url” instead of the value we assigned to in_url.

Do you have an example you can share where this solution works please?

Here is an example: (157.2 KB)

Thanks for this @Pablito. I can see in this that the variable is able to be used without delinking.

Just as a confirmation I think the difference between how you have added the screen to the Object Repo and how I have done it is that I didn’t add it from an existing Use Application/Browser that was in a sequence but just added a descriptor in the Object repo. Whereas I think from what you’re saying you added the screen to the repo via the the menu option in the Use application/browser activity.

From now on we’ll just create a use application/browser and link to the repo from there. I’ve just tried it that way and it looks to give us the ability to use variables without delinking from the repo.

Thanks for your help again.

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.

@Pablito can you provide more clarity on how to include this URL as a variable before adding it to the repo. Also, what packages do I need in order to view your example you provided in the initial topic?

My example contains whole project so you don’t need to install anything additional as project file have all needed dependencies in source.

You should be able to see how variable is added there:

I’ve added the variable like you have but in order for it to use that value I have to unlink from the object repository. Is there any way to do it without unlinking?

Also, I’m still unable to open your example. I get this error “Could not find member ‘Area’ in type ‘’. Row: 122, Column: 24” .
I’m on 20.10 and using the modern design experience with all update dependencies.

Look like the only way to have dynamic URL (URL as a variable) without unlinking/relinking (a lot of rework) is to erase all the hardcoded browser URL from all the screens in the Object Repo. After that, we’ll just need to use Go to URL activity in the InitAllApplication workflow inside Use Application/Browser. This assume all selectors are the same, just the URL is different.

1 Like

@grlawlf @Pablito I have yet to try this out but I believe you can use the {{variableName}} syntax and that should allow you to reference a variable so that it’s value is used … e.g. Url

1 Like

Hi Pablito, I created a new topic that is similar (but I think different) to this one.
If you have time I’d appreciate if you can take a look and advise.
Thank you