Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 297
  • Last Modified:

Visual J++ Wont Work!

I have installed Visual J++ on my machine which is running Windows NT.

Whenever I try to run or compile a project I get the following error:

"Solution Package

Solution update failed, some files may not be updated - detailed information is listed in the task window. To continue & launch debug process, click ok. To stop the process click cancel. "

If I click cancel nothing happens.

Now if I choose OK I get:

"ERROR: Could not execute class 1 the system cannot find the file specified"

Then im forced to click OK and nothing happens.

I have a feeling it has something to do with the classpath, I set up Visual J++ on a Win98 machine with no problems.

Any help would be greatly appreciated,

thanks




0
colin_cool
Asked:
colin_cool
  • 4
  • 2
1 Solution
 
Le_RonCommented:
Hi Colin,
first of all, you should take a look to the task window as said in the message. Maybe you'll find a more complete description of the problem(s).
I also used MSJ++ under WinNT and i also had some troubles with the classpath. Unfortunately, this is still not clear for me but what i know may help you:
You have some directories in the winnt\java directory: 'classes', 'packages' and 'trustlib' where - i guess - all your packages have to be. This is the default location checked by the JVC (the compiler). An interresting command is the clspack. e.g. 'clspack -auto' creates a 'classes.zip' file in the winnt\java\classes directory that contains all Java packages currently installed by the packages manager.
You also have the 'classpath' environment variable and the the registry values for the classpath and the packages.
I hope this helps you understanding a bit more how it works. Everything goes well on my computer now, but i changed so many things that i am not able to say exactly what has to be where.

Maybe you'll find answers at : http://msdn.microsoft.com/library/periodic/period98/vji0798c.htm
0
 
TarifCommented:
Make sure that the name of the class containing your "main method" matches the <classename.java> in the project explorer.  Also check if you have no syntax errors in task list.
0
 
colin_coolAuthor Commented:
Thanks for the help guys.

Le Ron: Thanks for all that info, it gave me a better understanding of how things work ;-)

Tarif: Thanks for the tip, the class containing the main method does match the classname in the project explorer. The class name is Class1 and in the explorer window it is the same.

This is the most basic project you can create, it just has one java file, i have tried various java files all which compile under JDK.

I think I have isolated this problem a bit more.

What I did was to compile the class1.java file using the JDK to get the Class1.class file in the Visual J++ project directory.

Then, when I ran the project in Visual J++ it worked - I think this rules out the classpath being the problem, as once the .CLASS file is there it can find it.

Therefore, It looks like there is a problem actually generating the .CLASS file (that is what the 'solution update' message is saying)

The problem is that I can see absolutely no way of troubleshooting this, all the debug windows are empty, there is nothing in the task list window, the first error message occurs immediately. The way I see it the error: 'solution update failed' is simply saying 'i cannot create the .CLASS file for some reason' then the 2nd error:  "ERROR: Could not execute class 1 the system cannot find the file specified" is saying 'the class file has not been created so i can't find it'

If I just try to build, rather than execute the project I only get the first error.
 
I notice when I go to project properties, there are various flags etc...you can set at the execute stage and you can pick the executable to use (WJView), and the location of the CLASS file, this can be run from the command prompt for instance with various flags -this is no help since the .CLASS file can't be created.

In the compile stage It doesn't appear to be using an executable???? I would like to compile from the dos prompt with some flags set for debugging.etc.. but I can't see how to do this.

Any further suggestions on troubleshooting this would be much appreciated, its driving me crazy! ;-P

Thanks.
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
colin_coolAuthor Commented:
Adjusted points from 50 to 85
0
 
Le_RonCommented:
Hi Colin,

of course, your project has to be configured with the good parameters (which file should be run, ...) and maybe you should take a look at the classpath tab, it may be useful to check whether all directories are OK.

I also found an answered question in the MSDN, maybe it could help :

Whenever I attempt to compile a program, a "Solution Update Failed" message appears in Visual J++ 6.0. However, there are no tasks in the Task List. Why can't I compile anything?

Answer:

You might have an incorrect version of the file Comcat.dll installed on your computer.

There are two versions of this DLL:

Version 4.71: 22 KB (CORRECT version)
Version 5.00: 6 KB (INCORRECT version)
If you are running Windows NT and you find Comcat.dll version 5.0 on your system, do the following:


Unregister Comcat.dll version 5.0. To do this, on the Start menu, click Run, and type regsvr32 /u Comcat.dll.


Delete or rename the incorrect Comcat.dll file.


Copy Comcat.dll 4.71 version from the Visual J++ 6.0 CD to your [windir]/system[32] directory.

NOTE: You will find the correct version on the CD in the \Common\Ide\Ide98\Redist directory.


Register version 4.71.To do this, on the Start menu, click Run, and type regsvr32 Comcat.dll.


In the Control Panel, click Add/Remove Programs, select Microsoft Visual J++ 6.0, and click Reinstall to "repeat the last installation to restore missing files and settings".


0
 
colin_coolAuthor Commented:
Adjusted points from 85 to 100
0
 
colin_coolAuthor Commented:
Le Ron: you are a LEGEND!

Thanks matey, that worked! ;-))

Who would have thought a file so small could cause such a headache?? hehe

Thanks again for the help..much appreciated! your the best.



0

Featured Post

Vote for the Most Valuable Expert

It’s time to recognize experts that go above and beyond with helpful solutions and engagement on site. Choose from the top experts in the Hall of Fame or on the right rail of your favorite topic page. Look for the blue “Nominate” button on their profile to vote.

  • 4
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now