How recompile cs file in activity of invoke code when debug or run the studio proj?

namespace MySql.src
{
    public class User
    {
        public static String  symbol1 = "hello jack";
    }
}
  1. new a proj “MySql”; and new a csharp file “User.cs” like top code
  2. new a invoke code activity and use code **Console.WriteLine("MySql.src.User.symbol1)**;
  3. run maybe error, reopen the proj, run success and log hello jack

and next
4. i add the new var symbol2 in User.cs, public static String symbol2 = "hello tom";.
5. the invoke code use **Console.WriteLine("MySql.src.User.symbol2)**;
6. trying debug or run again the proj, showing error of No compiled code to run error CS0117: 'User' does not contain a definition for 'symbo2' At line 43

but the symbol2 is useful in the variables

  1. when i reopen the proj, the symbol2 is useful in the invoke code.

it’s what happen of invoke code? has any proj config setting for recompile the cs file when i modify the cs code in the cs file ?

the ide is UiPath Studio Community

@geekcxyz

To understand better can you attach the project here

Cheers

proj here MySql.zip
sorry i cannot upload the zip, because freshman

@geekcxyz

I see the issue…so I tried closing the xamls and .cs file and then refresh and then reopen the main and it works

close all files not project…then refresh and then reopen main

cheers

oh it works. but i dont understand why the debug/run action not refresh the invoke code reference of .cs file

1 Like

and i get the other . if new a .cs file, must reopen project. this way not works.

1 Like

@geekcxyz

Glad that helped

Let me check on the second one too…but these might be improvements that are needed as of now…

Its not invoke code is refreshed its more because thw .local .peoject folders are to be updated as these are dynamic classes that are being created so its more on the ca file refresh rather than invoke code

Cheers

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