求教“javax.naming.NameNotFoundException: Name is not bound in this Context”
请大家指出错误谢谢~控制台报错为“avax.naming.NameNotFoundException: Name is not bound in this Context”
package com.ncs.util;
import java.sql.*;
import javax.naming.*;
import javax.sql.DataSource;
public class util {
public static Connection getPoolConnection() throws Exception{
Context ctx=new InitialContext();
DataSource ds=(DataSource)ctx.lookup("java:comp/env/jdbc/StrutsTestPool");
Connection conn=ds.getConnection();
return conn;
}
}
<?xml version="1.0" encoding="UTF-8"?>
<context>
<Resourse