Need explanation on highlighted code : Level 3 Lesson 1,Framework Video-State machine


1)Can someone explain what is the the use of condition “Config is Nothing”
Because i assume config is of type dictionary and we havnt initialised it to anything.
So whats the actual point of this condition.

2)Next question is that why is initallapplications.xaml outside if loop.
Since InitAllsettings and KillAllprocesses.xaml are in if loop.Why cant even this be within if loop.

3)For this program,i am invoking workflow files which i extracted from REFramework folder downloaded from GITHUB.Do we need to import these files seperately into studio.
Or invoking is enough.

This forum has been amazing with regards to UI path studio queries…
Thank u for taking out time to reply (In advance :slight_smile:

Thank you,

  1. The condition is just to check if the Config has any data or not. You are correct the data is stored to Dictionary type so it just need to check if we need to any thing in it so it doesn’t end up throwing exception as nothing in the data row!!! Hope this helps…

  2. Again if we remove it, it won’t error out but wastage of resources :frowning:

  3. Usually it’s a standard way to keep the workflow in the folder you develop the code. You can take a look at all the workflow in the Project tab.

Does that mean when we start,the config is empty.And we are just ensuring that before beginning any settings/process?

I assume you mean if the config file is empty!!!
The config file is basically used to make your code more dynamic and you being able to us most of the variables from the config directly :slight_smile:

I hope this helps you

I partly get it shubham.

My query is what is the need for that if loop with condition.
We anyways initialise just once.Why not keep it like a sequence.

Why to put it under a if loop ?

Ok so we have the first loop to read the config file, and the 2nd invoke process is for application i.e. can be used for 2nd run and to login and etc task. It’s not included in the first go!!!

Thank u Shubham.I got some clarity now.

So basically the condition “config is nothing” is only for first run.

if in case,you come back to this state after few runs,no need to read config file again.

This will work only if you are connected with Orchestrator, if you have removed it and make it run without it, the first run condition won’t work and will execute every time!!!

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