importing weblogic.common.*

Posted on 2006-06-25
Last Modified: 2008-02-01

I am trying to JNDI capabilities thru weblogic and access a particular database. For my InitialContextTest class, I need to import weblogic.common and weblogic. How do I import those jar files? I couldn’t find in c:\ bea dir.

Question by:dkim18
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
LVL 92

Assisted Solution

objects earned 20 total points
ID: 16980426

Author Comment

ID: 16980483
I included all the jars in C:\bea81\weblogic81\server\lib, but still got this error.

import javax.naming.*;
import java.util.*;
import weblogic.common.*;
import weblogic.jndi.*;
Exception in thread "main" java.lang.Error: Unresolved compilation problems:
      weblogic cannot be resolved or is not a type
      Type mismatch: cannot convert from InitialContextTest to Context
      The constructor InitialContextTest(Hashtable) is undefined
      Type mismatch: cannot convert from InitialContextTest to Context
      The constructor InitialContextTest(Hashtable) is undefined

      at InitialContextTest.main(
LVL 92

Expert Comment

ID: 16980558
can u post your code
Optimize your web performance

What's in the eBook?
- Full list of reasons for poor performance
- Ultimate measures to speed things up
- Primary web monitoring types
- KPIs you should be monitoring in order to increase your ROI

LVL 30

Accepted Solution

Mayank S earned 150 total points
ID: 16981183
>> InitialContextTest to Context

You are probably using: InitialContextTest something = new InitialContext () ? You can use InitialContext obj = new InitialContext () ;

>> The constructor InitialContextTest(Hashtable) is undefined

You are probably using InitialContextTest context = new InitialContextTest ( hashtable ) ; You need to use: InitialContext context = new InitialContext ( hashtable ) ;
LVL 35

Assisted Solution

girionis earned 80 total points
ID: 16990939
If the InitialContextTest is your own class you will need to create an object of that type.
LVL 30

Expert Comment

by:Mayank S
ID: 16992123
That's perhaps what he's trying to do but using it as though its an InitialContext, I guess....
LVL 30

Expert Comment

by:Mayank S
ID: 16999428
Any reason for the B grade?

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Java Flight Recorder and Java Mission Control together create a complete tool chain to continuously collect low level and detailed runtime information enabling after-the-fact incident analysis. Java Flight Recorder is a profiling and event collectio…
In this post we will learn how to connect and configure Android Device (Smartphone etc.) with Android Studio. After that we will run a simple Hello World Program.
Viewers will learn about if statements in Java and their use The if statement: The condition required to create an if statement: Variations of if statements: An example using if statements:
This tutorial will introduce the viewer to VisualVM for the Java platform application. This video explains an example program and covers the Overview, Monitor, and Heap Dump tabs.

636 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question