Connecting Tech Pros Worldwide Help | Site Map

Conversion from Java to C# in Visual Studio 2008

=?Utf-8?B?RmxhdmVsbGUgQmFsbGVt?=
Guest
 
Posts: n/a
#1: Dec 22 '07
Apparently the Java Conversion tool that used to be in Visual Studio 2005 is
no longer supported in Visual Studio 2008. Anyone have any suggestions on how
to convert a Java program to C# in Visual Studio 2008?
=?Utf-8?B?RmFtaWx5IFRyZWUgTWlrZQ==?=
Guest
 
Posts: n/a
#2: Dec 22 '07

re: Conversion from Java to C# in Visual Studio 2008




"Flavelle Ballem" wrote:
Quote:
Apparently the Java Conversion tool that used to be in Visual Studio 2005 is
no longer supported in Visual Studio 2008. Anyone have any suggestions on how
to convert a Java program to C# in Visual Studio 2008?
I've always done it by hand. I never used it, but thought the old VS
brought java in as JSharp.
Jon Skeet [C# MVP]
Guest
 
Posts: n/a
#3: Dec 22 '07

re: Conversion from Java to C# in Visual Studio 2008


Family Tree Mike <FamilyTreeMike@discussions.microsoft.comwrote:
Quote:
Quote:
Apparently the Java Conversion tool that used to be in Visual Studio 2005 is
no longer supported in Visual Studio 2008. Anyone have any suggestions on how
to convert a Java program to C# in Visual Studio 2008?
>
I've always done it by hand. I never used it, but thought the old VS
brought java in as JSharp.
Indeed - a hand-crafted conversion is likely to end up with much better
code, particularly in terms of using things like generics. (As far as
I'm aware the old conversion assistant only coped with 1.1 code anyway,
which is rather a limitation, given that Java 1.2 was released nearly
10 years ago...)

--
Jon Skeet - <skeet@pobox.com>
http://www.pobox.com/~skeet Blog: http://www.msmvps.com/jon.skeet
World class .NET training in the UK: http://iterativetraining.co.uk
=?Utf-8?B?RmxhdmVsbGUgQmFsbGVt?=
Guest
 
Posts: n/a
#4: Dec 22 '07

re: Conversion from Java to C# in Visual Studio 2008


So by hand is to setup the C# code, based on the Java code? Do you have any
suggestions on how to approach this, and are there references that will help.
I know C# fairly well, not a clue on Java.

"Jon Skeet [C# MVP]" wrote:
Quote:
Family Tree Mike <FamilyTreeMike@discussions.microsoft.comwrote:
Quote:
Quote:
Apparently the Java Conversion tool that used to be in Visual Studio 2005 is
no longer supported in Visual Studio 2008. Anyone have any suggestions on how
to convert a Java program to C# in Visual Studio 2008?
I've always done it by hand. I never used it, but thought the old VS
brought java in as JSharp.
>
Indeed - a hand-crafted conversion is likely to end up with much better
code, particularly in terms of using things like generics. (As far as
I'm aware the old conversion assistant only coped with 1.1 code anyway,
which is rather a limitation, given that Java 1.2 was released nearly
10 years ago...)
>
--
Jon Skeet - <skeet@pobox.com>
http://www.pobox.com/~skeet Blog: http://www.msmvps.com/jon.skeet
World class .NET training in the UK: http://iterativetraining.co.uk
>
Jonathan Sachs
Guest
 
Posts: n/a
#5: Feb 15 '08

re: Conversion from Java to C# in Visual Studio 2008


On Sat, 22 Dec 2007 01:27:00 -0800, Flavelle Ballem
<fballem@noemail.noemailwrote:
Quote:
>Apparently the Java Conversion tool that used to be in Visual Studio 2005 is
>no longer supported in Visual Studio 2008. Anyone have any suggestions on how
>to convert a Java program to C# in Visual Studio 2008?
This is a forlorn hope, but -- have there been any new developments or
discoveries on this front in the last couple of months?

I just purchased VS 2008 to convert and complete a large project which
was begun in Java, but which turned out to require some features which
are only available in .NET. I was aware that the converter was no
longer supported and no longer packaged with Visual Studio, but I knew
that it could be downloaded separately. I have now discovered that
with VS 2008 it won't even install.

I had expected to tweak this application's GUI (which is elementary)
and add some code to make the application communicate with Microsoft
Office. Now I'm looking at hand-converting thousands of lines of Java
code before I can even get started. If there's no way around this, I
may have to choose between abandoning the project and buying a copy of
VS 2005 which I will use just once. Neither prospect is appealing.
Jon Skeet [C# MVP]
Guest
 
Posts: n/a
#6: Feb 15 '08

re: Conversion from Java to C# in Visual Studio 2008


On Feb 15, 8:19 pm, Jonathan Sachs <js070...@sbcglobal.netwrote:

<snip>
Quote:
I had expected to tweak this application's GUI (which is elementary)
and add some code to make the application communicate with Microsoft
Office. Now I'm looking at hand-converting thousands of lines of Java
code before I can even get started. If there's no way around this, I
may have to choose between abandoning the project and buying a copy of
VS 2005 which I will use just once. Neither prospect is appealing.
To be honest, you're likely to get a better result by hand conversion
anyway. You can convert it into *idiomatic* C# rather than converted
Java. I've seen projects which have taken the "convert from Java"
approach, and it's very obvious and offputting. It's also hard to fix
after you've started.

Jon
Jonathan Sachs
Guest
 
Posts: n/a
#7: Feb 15 '08

re: Conversion from Java to C# in Visual Studio 2008


On Fri, 15 Feb 2008 12:23:46 -0800 (PST), "Jon Skeet [C# MVP]"
<skeet@pobox.comwrote:
Quote:
>To be honest, you're likely to get a better result by hand conversion
>anyway. You can convert it into *idiomatic* C# rather than converted
>Java. I've seen projects which have taken the "convert from Java"
>approach, and it's very obvious and offputting. It's also hard to fix
>after you've started.
I know you're trying to offer consolation, but that really doesn't
change anything. The project is at the proof-of-concept stage; the
code doesn't have to be efficient or maintainable, but it has to work.
There will be plenty of time to do a clean conversion once the proof
of concept is finished, but if I can't finish it without a ton of
work, I probably won't get it finished it at all.
Alun Harford
Guest
 
Posts: n/a
#8: Feb 15 '08

re: Conversion from Java to C# in Visual Studio 2008


Jonathan Sachs wrote:
Quote:
On Sat, 22 Dec 2007 01:27:00 -0800, Flavelle Ballem
<fballem@noemail.noemailwrote:
>
Quote:
>Apparently the Java Conversion tool that used to be in Visual Studio 2005 is
>no longer supported in Visual Studio 2008. Anyone have any suggestions on how
>to convert a Java program to C# in Visual Studio 2008?
>
This is a forlorn hope, but -- have there been any new developments or
discoveries on this front in the last couple of months?
>
I just purchased VS 2008 to convert and complete a large project which
was begun in Java, but which turned out to require some features which
are only available in .NET. I was aware that the converter was no
longer supported and no longer packaged with Visual Studio, but I knew
that it could be downloaded separately. I have now discovered that
with VS 2008 it won't even install.
IIRC it will only do Java 1.1 anyway (or maybe 1.2 - I don't remember)

Alun Harford
Rad [Visual C# MVP]
Guest
 
Posts: n/a
#9: Feb 19 '08

re: Conversion from Java to C# in Visual Studio 2008


On Fri, 15 Feb 2008 20:19:13 GMT, Jonathan Sachs wrote:
Quote:
months?
You don't need to buy the Visual Studi for that one use. You could always
download a trial version from the Microsoft site and use that to convert.
Although I would be surprised if you didn't have to do some grunt work
yourself
--
http://www.thinkersroom.com/bytes
Jonathan Sachs
Guest
 
Posts: n/a
#10: Feb 19 '08

re: Conversion from Java to C# in Visual Studio 2008


On Tue, 19 Feb 2008 23:19:35 +0300, "Rad [Visual C# MVP]"
<nospam@nospam.comwrote:
Quote:
>You don't need to buy the Visual Studi for that one use. You could always
>download a trial version from the Microsoft site and use that to convert.
That is a very interesting possibility. Can you tell me where to get
the download? I'm surprised that Microsoft still offers a free trial
of a product that is no longer being sold.

I found what appears to be the former starting point for downloading
trials of Visual Studio 2005, but the download links have been
stubbed.

http://msdn2.microsoft.com/en-us/ie/bb188238.aspx
Closed Thread


Similar C# / C Sharp bytes