Convert VB.NET code in C #

Is there a library that I can use to convert VB.Net code to C #? There is http://codeconverter.sharpdevelop.net/ , but I do not want to use it from a web service.

+4
source share
3 answers

There are many online services: Telerik provides one , here is another and one of the best developers to merge . But they are all online.

I had a good impression of Instant C # of Tangible Solutions , they provide good services for every error that you encounter after the conversion. In addition, Turnsharp , and many others are available through Google.

If you use Reflector, a few notes: it does not translate your source code, but compiled code. This can significantly affect the logic inside the methods and, first of all, you will lose all your (xml) comments and, possibly, your file structure (for example, partial classes are not recognized). Reflector is practically not applicable when it comes to ASPX and inline code. But this is a great free tool in every other way.

+5
source

Open the assembly in .NET Reflector. Choose C # language. Copy / paste the source code into Visual Studio. Try compiling.

+9
source

Just download SharpDevelop 4.4, it contains the same converter for offline use.

In fact, the SharpDevelop converter is even better than the online converter, as it can take a look at your entire project and your links.

The SharpDevelop source code repository also contains the complete source code for this website. All this is open source.

+2
source

Source: https://habr.com/ru/post/1316403/


All Articles