0

I have several VB programs that I wrote a few years ago in school. Is there any way possible to convert those programs to Java? Or would that it be easier to just rewrite it from scratch? My goal is to create an Android app that combines at least two of the programs into one functional app. This is purely a nonprofit endeavor; I'm a full time firefighter and am looking to put a free tool in the hands of my guys and other firemen who might want to use it.

I've been unable to locate the source code for the programs and have searched for an answer but haven't been able to find a definitive answer as most answers cover the source, not the compiled result. I've downloaded a couple supposed VB decompilers to see the results, but, in order to see the 'full' results, all the ones I've used require purchasing a 'pro' version. I have no problem paying for such a version, but I'd like to know if it's going to work properly before I do.

  • What you are trying to do might become really difficult. If you don't have the source codes, better start from scratch. – varocarbas Nov 27 '13 at 14:05
  • I thought that would be the answer but I figured this was the place to ask to be sure. Thanks for your quick answer. – user3042034 Nov 27 '13 at 14:10
  • Can you remember the algorithms and general concepts of the VB programs? If so, there is little value to retrieving the source. – Patricia Shanahan Nov 27 '13 at 14:15
  • if you have written it before, you will be able to write it again, even better than you have done in school. Also, translating from VB to Android will be much more painful than just decide what you want to do, look up how it should be done in android and just do it. – mihail Nov 27 '13 at 14:22
  • @PatriciaShanahan The OP does not know anything about decompiling; so he would have to learn to do that; he would get a not so perfect source code which would have to convert (thus basic knowledge of VB wouldn't be enough; additionally he has to merge small programs into a bigger one what might even prove to not be a good solution; and a full from scratch development might be proven to be required anyway). Unless involving a complex implementation (what does not seem to be the case from the description), he shouldn't consider the decompiling option at all. – varocarbas Nov 27 '13 at 14:24
  • 1
    @varocarbas My view is that the only use of decompiling would be to read the programs to recover non-trivial ideas the OP worked out while writing them but has since forgotten. Those ideas may shorten the design work for the Java programs. If the OP remembers the ideas, then there is no point at all in decompiling. I do not recommend attempting to translate the programs. – Patricia Shanahan Nov 27 '13 at 14:33
  • @PatriciaShanahan Now everything is completely clear, thanks. – varocarbas Nov 27 '13 at 14:38
  • I do remember the ideas. Mostly it's mathematical formulas based on user input and the inputs are constant (there are only certain sizes of hoses in use, for example). It'll probably do me some good to brush up on my Java skills, since it's been years since I wrote anything. Thanks for your help too, Patricia and mihail. – user3042034 Nov 27 '13 at 15:00

1 Answers1

0

It would definitely be faster to rewrite them than it would be to devise a way of converting a VB program into Java code. Not only are the languages quite dissimilar, but VB's UI model is nothing like Android's, so it would likely be impossible (or at least impractical) to translate the UI code automatically.

Mike Strobel
  • 25,075
  • 57
  • 69