|
-
September 30th, 1999, 03:46 PM
#1
Help Needed : Ambigious class
I have the following imports on my java file.
import java.awt.*;
import java.util.*;
private List list;
When I try to compile, I'm getting a ambigious class definition for list error.
How do I solve the problem ? I need to use both the java.util and java.awt.
-
September 30th, 1999, 04:10 PM
#2
Re: Help Needed : Ambigious class
Reason is List is there in AWT and as well as java.util.*
Write like this
import java.awt.*;
import java.util.*;
private java.awt.List myList;
Meher
-
September 30th, 1999, 04:15 PM
#3
Re: Help Needed : Ambigious class
Yes there are two list class in java ( in awt & util ). Which List class you want. If you
like to create an instance of java.awt.List class , try like this ..
private java.awt.List list = new java.awt.List();
This will solve your problem..
poochi...
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|