配置如下:

<init-param>
   <param-name>contextConfigLocation</param-name>
   <param-value>classpath:spring/ApplicationContext-springmvc.xml</param-value>
  </init-param>

原因是:IDE认为spring文件夹是在source下的,所以找不到

解决方案:

在classpath后面加个*

如下:

<init-param>
   <param-name>contextConfigLocation</param-name>
   <param-value>classpath*:spring/ApplicationContext-springmvc.xml</param-value>
  </init-param>

class path resource [spring/ApplicationContext-springmvc.xml] cannot be opened because it does not exist的更多相关文章

  1. 解决CXF的java.io.FileNotFoundException: class path resource [META-INF/cxf/cxf-extension-soap.xml] cannot be opened because it does not exist

    以下是错误信息 九月 25, 2017 8:22:04 下午 org.springframework.web.context.support.XmlWebApplicationContext prep ...

  2. spring junit class path resource [ /com/config/spring-core.xml] cannot be opened because it does not exist

    正确写法应该如下: @RunWith(SpringJUnit4ClassRunner.class) //@ContextConfiguration(locations="classpath: ...

  3. java.io.FileNotFoundException: class path resource [META-INF/xfire/services.xml] cannot be opened because it does not exist

    解决办法: maven创建项目时: META-INF目录下面新建一个xfire文件夹,把services.xml文件放到这个文件夹里,再将整个META-INF拷贝到WEB-INF中 clean一下工程 ...

  4. spring整合mybatis错误:class path resource [config/spring/springmvc.xml] cannot be opened because it does not exist

    spring 整合Mybatis 运行环境:jdk1.7.0_17+tomcat 7 + spring:3.2.0 +mybatis:3.2.7+ eclipse 错误:class path reso ...

  5. class path resource [spring/applicationContext.xml] cannot be opened because it does not exist

    1.查看路径有没有写错 2.编辑器认为你的文件不是 source folders(原文件),需要你手动将文件改过来

  6. 启动tomcat报错Caused by: java.io.FileNotFoundException: class path resource [io/renren/controller/NodeDataController] cannot be opened because it does not exist

    ?? 清理项目,再重启服务就好了.........

  7. cxf(3.1.1) 异常Caused by: java.io.FileNotFoundException: class path resource [META-INF/cxf/cxf-extension-soap.xml]

    Caused by: java.io.FileNotFoundException: class path resource [META-INF/cxf/cxf-extension-soap.xml] ...

  8. Caused by: java.io.FileNotFoundException: class path resource [spring/springmvc.xml] cannot be opene

                        Caused by: java.io.FileNotFoundException: class path resource [spring/springmvc. ...

  9. Spring报错:java.io.FileNotFoundException: class path resource [applicationContext.xml] cannot be opened because it does not exist

    感谢:http://blog.chinaunix.net/uid-20681545-id-184633.html提供的解决方案,非常棒 ! 问题说明: 新建一个Spring项目,新建一个Bean类:H ...

  10. parsing XML document from class path resource [config/applicationContext.xml]; nested exception is java.io.FileNotFoundException: class path resource [config/applicationContext.xml] 解决方案

    parsing XML document from class path resource [config/applicationContext.xml]; nested exception is j ...

随机推荐

  1. Python扩展库2—matplotlib

    1 载入matplotli的绘图模块,并重命名为plt import matplotlib.pyplot as plt 2 折线图 import matplotlib.pyplot as plt im ...

  2. Window下部署Maven Nexus

    Nexus下载地址:https://www.sonatype.com/download-oss-sonatype 选择相应的版本下载后,本人下载的是nexus-2.12.0-01-bundle.zip ...

  3. 标准I/O读写文件

    一.函数原型 1.FILE *fopen(const char *path, const char *mode); path:要打开文件路径及文件名: mode:  r 打开只读文件,该文件必须存在. ...

  4. 首席数据官(CDO)的崛起

    数据在我们的日常生活中发挥着核心作用,几乎渗透到商业和公共部门的每一项活动中.它现在被认为是任何一个严肃组织的难题之一,可以实现从改变游戏规则的洞察到整个新技术或商业模式的诞生. 事实上,现在数据非常 ...

  5. OTG作为大容量设备

    /********************************************************************************* * OTG作为大容量设备 * 说明 ...

  6. fixed不能罩住下面的内容

    fix的优先级并不是最高的,所以要设置z-index,比它下面的元素高就能遮住了

  7. lecture1-Word2vec实战班-七月在线nlp

    nltk的全称是natural language toolkit,是一套基于python的自然语言处理工具集.自带语料库.词性分类库.自带分类分词等功能.强大社区支持.很多简单版wrapper 文本处 ...

  8. Spring mvc 导出table到Excel

    /** * * @Title: exportExcel * @Description: TODO(导出到excel) * @param Page page * @return ModelAndView ...

  9. Linux压缩文件笔记

    https://my.oschina.net/dongqianlin/blog/97168http://linux.it.net.cn/CentOS/fast/2017/0628/27029.html ...

  10. c# 敏捷3 连接,批量处理,分页

    class Program { public class post { public int id { get; set; } public string name { get; set; } pub ...