<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta http-equiv="Content-Type" content="text/html;charset=ISO-8859-1">
  <title></title>
</head>
<body>
<font face="Helvetica, Arial, sans-serif"><small>Dear all,<br>
<br>
I am trying to create a new file from a jsp fragment code, using
openCMS APIs.<br>
In particular, I used method createResource(cmsObject cms, string name,
Map properties, byte[] content, HashMap parameter) from class
com.opencms.file.CmsResourceTypePage.<br>
<br>
But it doesn't seem to work properly. If I give a name like
/opencms/opencms/something/file.html I obtain this exception </small></font><br>
<font face="Courier New, Courier, monospace"><small>com.opencms.core.CmsException:
2 Not found. Detailed error: [com.opencms.file.mySql.CmsDbAccess]
/default/vfs/opencms/opencms/something/<br>
        at
com.opencms.file.genericSql.CmsDbAccess.readFolder(CmsDbAccess.java:8259)<br>
        at
com.opencms.file.genericSql.CmsResourceBroker.readFolder(CmsResourceBroker.java:5608)<br>
        at
com.opencms.file.genericSql.CmsResourceBroker.readFolder(CmsResourceBroker.java:5575)<br>
        at
com.opencms.file.genericSql.CmsResourceBroker.createFile(CmsResourceBroker.java:1786)</small></font><br>
...<br>
<font face="Helvetica, Arial, sans-serif"><small><br>
and if I give only a name like file.html I obtain this</small></font><br>
<small><font face="Courier New, Courier, monospace">com.opencms.core.CmsException:
2 Not found. Detailed error: [com.opencms.file.mySql.CmsResourceBroker]
null.<br>
        at
com.opencms.file.genericSql.CmsResourceBroker.getResourceType(CmsResourceBroker.java:3769)<br>
        at
com.opencms.file.genericSql.CmsResourceBroker.createFile(CmsResourceBroker.java:1789)<br>
        at com.opencms.file.CmsObject.doCreateFile(CmsObject.java:978)<br>
        at
com.opencms.file.CmsResourceTypePage.createResource(CmsResourceTypePage.java:461)<br>
</font></small>...<br>
<small><font face="Helvetica, Arial, sans-serif"><br>
I suppose (afer looking class sources) there is a wrong separator ("/")
management.<br>
<br>
Is there anyone who can give me a hint on how to proceed, like use
another class / method?<br>
<br>
Thanks a lot<br>
    Giuseppe</font></small><br>
</body>
</html>