Kabeer
(Kabeer)
January 18, 2022, 10:03pm
1
Hello All,
Require some guidance on the below issue.
BOT is running fine with the older system activity (19.0)
When we have updated the system activity to higher version(21.0). I am getting the error like My.computer method is not compile in Invoke code( code in vb.net ).
Can you share your screenshot and error message? Too little information is posted in your message.
Kabeer
(Kabeer)
January 19, 2022, 9:28am
3
Hi Shubin,
Thanks for the response.
Kindly have look at the attached image.
When we have updated the system package to higher version like 21.1.0 or above. We are getting this error.
If the system package is in 19.1.0 like that BOT is running fine.
Hi Kabeer
What is inside your invoke method? Can you run it on another computer with the latest version of system activity?
The issue is possible due to your computer.
Kabeer
(Kabeer)
January 20, 2022, 12:07pm
5
Ok let me try with other machine and let you know the outcome.
The purpose of the VB code is to check the notepad file is exists or not.
If yes then it will check whether it’s contain the particular string in the notepad file.
Another option is to use UiPath
> File Exists
activity as shown below, to check if a file exists.
Yoichi
(Yoichi)
January 21, 2022, 3:49am
7
Hi,
We can also use Microsoft.VisualBasic.Devices.Computer
instance instead of My.Computer
as the following. (It’s exactly same.)
(new Microsoft.VisualBasic.Devices.Computer).FileSystem.FileExists("c:\temp\test.txt")
(new Microsoft.VisualBasic.Devices.Computer).Name
Or we can use System.IO.File.Exists
method, too , if we want to check file exists.
Regards,
Kabeer
(Kabeer)
January 22, 2022, 3:03pm
8
Hi Shubin,
Yeah I am aware of that . Since we have used the VB.net code already I tried to figure it out in the same method.
Kabeer
(Kabeer)
January 22, 2022, 3:04pm
9
Thanks Yoichi,
I will try this and let you know whether it’s worked fine or not.
Yoichi
(Yoichi)
February 2, 2022, 1:01pm
11
Hi,
It seems matter of InvokeCode activity. If possible, can you try to downgrade System.Activities package to 20.10.x?
@Shilpa_Mohanty @prasath_S @StefanSchnell
Hi,
I can just reproduce this problem in my environment as the following.
[img20211206-2]
I haven’t get the exact conditions for reproduction yet, but In Studio 20.10.9 with System.Activities package 21.10.2 this occurs. If downgrade System.Activities package to 20.10.4 (this is bundled version of Studio 20.10.9) , there is no error.
So for now can you try to downgrade System.Activities package to 20.10.4, if you use Studio except the latest.
Rega…
Regards,
system
(system)
Closed
February 5, 2022, 1:01pm
12
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.