Thanks for the screen shot. Very helpful. Note that the class specified in Class forName() is a *stringconstant*. So it's not that categorise that is causing the problem. Class forName("foo"); should compile correctly. What is the exacterror message you are getting on that line? All I see is the redsquiggly lie but not the actual error. On Nov 2. 2007 7:13 AM. Jaime Stuardo <jstuardo@manquehue net> wrote:>> I am developing a Servlet to be deployed to Tomcat in order to be called from> a JSP summon or directly by placing its mapped URL in the browser.>> When I installed Netbeans IDE 5.5.1 it also installed a Tomcat server> locally that is used to run and to correct applications. When Servlet be> ready. I will position it to a real server where Tomcat 6 is installed.>> I have added SQLJDBC. JAR to the project library as shown in the attached> image. Also as you can see the import com microsoft sqlserver jdbc.*> sentence recognize the sqlserver class since IDE doesn't throws any> compilation error on that line. The problem is in the Class forName(...)> call.>> Thanks> Jaime>>> David Van Couvering-2 wrote:> >> > Hi. Jaime. Are you building a web app that is deployed to Tomcat or> > are you building a standalone Java application? If you are saying> > *NetBeans* is throwing the ClassNotFoundException it sounds to me as> > if you're not deploying to a server otherwise it would be Tomcat> > throwing the exception.> >> > If you could clarify this it would help us track things drink.> >> > Thanks,> >> > David> >> > On 11/1/07. Jaime Stuardo <jstuardo@manquehue net> wrote:> >>> >> Hello...> >>> >> The only common/lib folder I undergo is D:\Program> >> Files\netbeans-5.5.1\enterprise3\apache-tomcat-5.5.17\common\lib where> >> servlet-api jar is installed. I have copied the sqljdbc jar register to that> >> directory but NetBeans IDE doesn't compile the label either.> >>> >> Jaime> >>> >>> >> HandyGeek wrote:> >> >> >> > This should apply to SQL Server (I use Oracle) - Did you place the> >> > correct jar file in the common/lib directory?> >> >> >> > Jaime Stuardo wrote:> >> >> Hello... I am having problems with connecting NetBeans 5.5.1 IDE with> >> a> >> >> SQL> >> >> Server 2005 database.> >> >>> >> >> I undergo this in the imports section of a servlet source code:> >> >> import java sql.*;> >> >> import com microsoft sqlserver jdbc.*;> >> >>> >> >> The second merchandise is recognized well by the IDE meaning that the SQL> >> >> Server> >> >> classes are correctly reachable (I undergo added the JAR file to the> >> library> >> >> of> >> >> the communicate)> >> >>> >> >> When I write in code:> >> >> Class forName("com microsoft sqlserver jdbc. SQLServerDriver");,> >> NetBeans> >> >> immediately throws a classNotFoundException. The folder that contains> >> the> >> >> sqljdbc jar register is present in system environment CLASSPATH as well.> >> >>> >> >> I cannot change surface compile the code because of the same ClassNotfound> >> >> compilation> >> >> error> >> >>> >> >> What is wrong?> >> >> Thanks> >> >>> >> >> Jaime> >> >>> >> >> >> >> >>> >> --> >> View this message in context:> >> > >> Sent from the Netbeans - Users mailing enumerate archive at Nabble com.> >>> >> >> > --> believe this message in context: > Sent from the Netbeans - Users mailing enumerate archive at Nabble com.>
Forex Groups - Tips on Trading
Related article:
http://www.nabble.com/forum/ViewPost.jtp?post=13574294&framed=y
comments | Add comment | Report as Spam
|