Cannot use some expressions in libraries

Error messages are displayed on my library when I use some expressions as follows.

  • rect.Width (rect is System.Drawing.Rectangle)
  • screen.Bounds.Height (screen is System.Windows.Forms.Screen)
  • obj = color (obj is System.Object, color is System.Drawing.Color)

I made a sample xaml file which causes the error messages.


(I cannot attach a file directly because I’m a new user.)

Thanks,

1 Like

Hi @ark

Just to clarify, did you add the correct namespaces to the source xaml file of your activity and/or referred to them with a whole path whenever used?

(I cannot check the xaml file right now, so skip the message if you did)

Hi @loginerror, thank you for your reply.
Yes, I did. And I can run this xaml file by itself.
But these messages are shown when I use the xaml file as a activity (compiled by UiPath Studio 2018.3).

1 Like

Hi @ark! Thanks for the heads up!
We managed to reproduce the problem ourselves and we just passed it to the development team for them to further investigate it.
We will keep you in the loop with this one.

1 Like

Hi @radutzp, thank you for your investigation.
I found a workaround.
No error messages weren’t displayed when I wrote the same expressions in “Invoke Code” activities.
I made a sample xaml file.
WorkaroundExpression.xaml (7.7 KB)

But it’s complicated a little.
So I hope this issue will be solved soon.

Thanks.

Hi @radutzp, thank you for your new versions.
I found this issue was fixed at 18.3.0-beta0558.
And I discovered another expressions which cause some errors.

I cannot use expressions which include UiPath.Core.* in a xaml-file created by old version UiPath.
For example, I cannot use UiElement Is Nothing in a xaml-file created by UiPath v2018.2.4

I made a sample xaml file.
Heritage.xaml (4.9 KB)

Is this by design?

Thanks.