3

Is there a solution [online or app] to convert a programming language to another one?

For example:

  • I have XAML code and I want to convert it to javaScript and otherwise.
  • I have C# code and I want to convert it to javaScript and otherwise.
durron597
  • 31,968
  • 17
  • 99
  • 158
Tassisto
  • 9,877
  • 28
  • 100
  • 157
  • 1
    you can't convert all C# in JavaScript so if there would be a tool for that it won't work always. – noob Jan 11 '12 at 10:15
  • 1
    Are you aware of the differences between the programming languages you mentioned? They are usually aimed at totally different applications. – Tadeck Jan 11 '12 at 10:16
  • Wow then we would all be flooding careers forum and answering job switching questions – V4Vendetta Jan 11 '12 at 10:18
  • Don't know which part of "For example" you guys don't understand? – Tassisto Jan 12 '12 at 11:08
  • 1
    In the case of Xaml to JavaScript, how deep must the translator go? If a control in the Xaml took a parameter setting from the static System Parameters class, things could get hairy pretty quick... – Gayot Fow Jan 12 '12 at 15:37

3 Answers3

5

when doing web development you're able to translate ASP.NET and C# code to JavaScript using Script# http://projects.nikhilk.net/ScriptSharp

I think you should review the ideas behind each of the languages to get an understanding of their goals.

Thorsten Hans
  • 2,675
  • 19
  • 21
4

In order to convert code both languages must be identical, for example C# to VB. Converting languages that serve different purposes is not feasible, and the only options are tricky and full of errors.

You can look at this one: http://michaelsync.net/2007/10/29/script-c-to-javascript-converter

Tassisto
  • 9,877
  • 28
  • 100
  • 157
T23
  • 582
  • 2
  • 11
2

look at this project (claims to do C#>Javascript :) also look at Script# see video here

robasta
  • 4,621
  • 5
  • 35
  • 53
  • The most complete and functional is [JSIL](http://jsil.org/) Has not fully language support, but it can translate some full games and software. – luiseduardohd Mar 20 '15 at 16:13