I’m going through the UiDemo (1st part) of the advanced training.
My code is failing when it tries to open the UiDemo app (using open application activity).
First I put a message box check the path
this is coming from in_Config(“UiDemoPath”).ToString
The problem occurs when it tries to Open Application UiDemo.exe
I thought perhaps that there may be a problem with the spaces in the path (in the ‘\Level 3 Advanced Training\’ part)
so I tried
C:\Users\hasee\Desktop\UIPathExamples\UiDemo.exe
and that worked fine.
So my question is how do I use a path that includes spaces when using the open application activity (I know I could change my path but I’m sure there will be situations where that is not an option and a path that includes spaces will be required).
Thanks for the input but since attempting your suggestion I’ve found that the problem is in fact not with the spaces in the way I originally thought.
Originally I was pulling the UiDemo path from orchestrator via in_Config(“UiDemoPath”).ToString (this in_config dictionary is populated by InitAllSettings workflow in the REFramework.
To test my theory about the spaces I put the no spaces path directly into the open application activity, Filename property (“C:\Users\hasee\Desktop\UIPathExamples\UiDemo.exe”) and it worked (at this point I thought therefore the problem must be with the spaces in the file path).
However I just put the filepath with spaces directly into the Filename property and that also worked (rather than using the in_Config(“UiDemoPath”).ToString.
But when I put the in_Config(“UiDemoPath”).ToString into the Filename property of the open application activity I get the error message and this doesn’t matter whether I use the path with or without spaces so the spaces may be a red herring.
I’ve put a message box so I can see the value of in_Config(“UiDemoPath”).ToString and it seems fine (example without spaces to avoid extra confusion) but this does not work and I get the error message shown earlier ‘workflow exeception’
This is the InitAllApplications workflow that I am trying to get to work
You bloody genius! That did work. But why did that work and open application not work (especially as it was what was in the walkthrough document).
I did post a comment saying that there should be a model answer for this piece of work as I’m not sure I would ever have known that open application is not the way forward (it would be great to understand why) and start process is.
Either way thanks for the help and please explain why that worked.
Haha , Not quite a genius yet! Surely will be someday
To be honest even i have a problem understanding the difference between the two.
I faced this situation sometime ago and just tried a few different things and this just worked!
You could have a new thread ,maybe somebody with more experience can help with the answer to that question!
It’s only been 2 months for me, still a lot to learn
Can I suggest that you put your post into a new item rather than adding it onto the end of this one as I expect it will get more attention than just addressing me on the problem.
Your main xaml is just standard. The problems you seem to be having are with dictionary keys (probably in the config dictionary) I had problems with the credentials so it may be there when it was filling the config dictionary it didn’t like the credential values for some reason, and closing applications which isn’t in the initallsettings xaml.
Try putting breakpoints into the code and stepping through using the debug functionality, but mostly post the problem separately so you get the best fixers on the job. They may know the answer straight away or may know what area to investigate (with me it took ages stepping through the code to find where a problem was and then quite often asking for help).